Best JavaScript code snippet using wpt
nav-data.js
Source:nav-data.js
1'use strict';2// Meta data used by the AngularJS docs app3angular.module('navData', [])4 .value('NG_NAVIGATION', {5 "api": {6 "id": "api",7 "name": "API",8 "navGroups": [9 {10 "name": "ng",11 "href": "api/ng",12 "type": "group",13 "navItems": [14 {15 "name": "function",16 "type": "section",17 "href": "api/ng/function"18 },19 {20 "name": "angular.bind",21 "href": "api/ng/function/angular.bind",22 "type": "function"23 },24 {25 "name": "angular.bootstrap",26 "href": "api/ng/function/angular.bootstrap",27 "type": "function"28 },29 {30 "name": "angular.copy",31 "href": "api/ng/function/angular.copy",32 "type": "function"33 },34 {35 "name": "angular.element",36 "href": "api/ng/function/angular.element",37 "type": "function"38 },39 {40 "name": "angular.equals",41 "href": "api/ng/function/angular.equals",42 "type": "function"43 },44 {45 "name": "angular.errorHandlingConfig",46 "href": "api/ng/function/angular.errorHandlingConfig",47 "type": "function"48 },49 {50 "name": "angular.extend",51 "href": "api/ng/function/angular.extend",52 "type": "function"53 },54 {55 "name": "angular.forEach",56 "href": "api/ng/function/angular.forEach",57 "type": "function"58 },59 {60 "name": "angular.fromJson",61 "href": "api/ng/function/angular.fromJson",62 "type": "function"63 },64 {65 "name": "angular.identity",66 "href": "api/ng/function/angular.identity",67 "type": "function"68 },69 {70 "name": "angular.injector",71 "href": "api/ng/function/angular.injector",72 "type": "function"73 },74 {75 "name": "angular.isArray",76 "href": "api/ng/function/angular.isArray",77 "type": "function"78 },79 {80 "name": "angular.isDate",81 "href": "api/ng/function/angular.isDate",82 "type": "function"83 },84 {85 "name": "angular.isDefined",86 "href": "api/ng/function/angular.isDefined",87 "type": "function"88 },89 {90 "name": "angular.isElement",91 "href": "api/ng/function/angular.isElement",92 "type": "function"93 },94 {95 "name": "angular.isFunction",96 "href": "api/ng/function/angular.isFunction",97 "type": "function"98 },99 {100 "name": "angular.isNumber",101 "href": "api/ng/function/angular.isNumber",102 "type": "function"103 },104 {105 "name": "angular.isObject",106 "href": "api/ng/function/angular.isObject",107 "type": "function"108 },109 {110 "name": "angular.isString",111 "href": "api/ng/function/angular.isString",112 "type": "function"113 },114 {115 "name": "angular.isUndefined",116 "href": "api/ng/function/angular.isUndefined",117 "type": "function"118 },119 {120 "name": "angular.lowercase",121 "href": "api/ng/function/angular.lowercase",122 "type": "function"123 },124 {125 "name": "angular.merge",126 "href": "api/ng/function/angular.merge",127 "type": "function"128 },129 {130 "name": "angular.module",131 "href": "api/ng/function/angular.module",132 "type": "function"133 },134 {135 "name": "angular.noop",136 "href": "api/ng/function/angular.noop",137 "type": "function"138 },139 {140 "name": "angular.reloadWithDebugInfo",141 "href": "api/ng/function/angular.reloadWithDebugInfo",142 "type": "function"143 },144 {145 "name": "angular.toJson",146 "href": "api/ng/function/angular.toJson",147 "type": "function"148 },149 {150 "name": "angular.uppercase",151 "href": "api/ng/function/angular.uppercase",152 "type": "function"153 },154 {155 "name": "directive",156 "type": "section",157 "href": "api/ng/directive"158 },159 {160 "name": "a",161 "href": "api/ng/directive/a",162 "type": "directive"163 },164 {165 "name": "form",166 "href": "api/ng/directive/form",167 "type": "directive"168 },169 {170 "name": "input",171 "href": "api/ng/directive/input",172 "type": "directive"173 },174 {175 "name": "input[checkbox]",176 "href": "api/ng/input/input[checkbox]",177 "type": "input"178 },179 {180 "name": "input[date]",181 "href": "api/ng/input/input[date]",182 "type": "input"183 },184 {185 "name": "input[datetime-local]",186 "href": "api/ng/input/input[datetime-local]",187 "type": "input"188 },189 {190 "name": "input[email]",191 "href": "api/ng/input/input[email]",192 "type": "input"193 },194 {195 "name": "input[month]",196 "href": "api/ng/input/input[month]",197 "type": "input"198 },199 {200 "name": "input[number]",201 "href": "api/ng/input/input[number]",202 "type": "input"203 },204 {205 "name": "input[radio]",206 "href": "api/ng/input/input[radio]",207 "type": "input"208 },209 {210 "name": "input[range]",211 "href": "api/ng/input/input[range]",212 "type": "input"213 },214 {215 "name": "input[text]",216 "href": "api/ng/input/input[text]",217 "type": "input"218 },219 {220 "name": "input[time]",221 "href": "api/ng/input/input[time]",222 "type": "input"223 },224 {225 "name": "input[url]",226 "href": "api/ng/input/input[url]",227 "type": "input"228 },229 {230 "name": "input[week]",231 "href": "api/ng/input/input[week]",232 "type": "input"233 },234 {235 "name": "ngApp",236 "href": "api/ng/directive/ngApp",237 "type": "directive"238 },239 {240 "name": "ngBind",241 "href": "api/ng/directive/ngBind",242 "type": "directive"243 },244 {245 "name": "ngBindHtml",246 "href": "api/ng/directive/ngBindHtml",247 "type": "directive"248 },249 {250 "name": "ngBindTemplate",251 "href": "api/ng/directive/ngBindTemplate",252 "type": "directive"253 },254 {255 "name": "ngBlur",256 "href": "api/ng/directive/ngBlur",257 "type": "directive"258 },259 {260 "name": "ngChange",261 "href": "api/ng/directive/ngChange",262 "type": "directive"263 },264 {265 "name": "ngChecked",266 "href": "api/ng/directive/ngChecked",267 "type": "directive"268 },269 {270 "name": "ngClass",271 "href": "api/ng/directive/ngClass",272 "type": "directive"273 },274 {275 "name": "ngClassEven",276 "href": "api/ng/directive/ngClassEven",277 "type": "directive"278 },279 {280 "name": "ngClassOdd",281 "href": "api/ng/directive/ngClassOdd",282 "type": "directive"283 },284 {285 "name": "ngClick",286 "href": "api/ng/directive/ngClick",287 "type": "directive"288 },289 {290 "name": "ngCloak",291 "href": "api/ng/directive/ngCloak",292 "type": "directive"293 },294 {295 "name": "ngController",296 "href": "api/ng/directive/ngController",297 "type": "directive"298 },299 {300 "name": "ngCopy",301 "href": "api/ng/directive/ngCopy",302 "type": "directive"303 },304 {305 "name": "ngCsp",306 "href": "api/ng/directive/ngCsp",307 "type": "directive"308 },309 {310 "name": "ngCut",311 "href": "api/ng/directive/ngCut",312 "type": "directive"313 },314 {315 "name": "ngDblclick",316 "href": "api/ng/directive/ngDblclick",317 "type": "directive"318 },319 {320 "name": "ngDisabled",321 "href": "api/ng/directive/ngDisabled",322 "type": "directive"323 },324 {325 "name": "ngFocus",326 "href": "api/ng/directive/ngFocus",327 "type": "directive"328 },329 {330 "name": "ngForm",331 "href": "api/ng/directive/ngForm",332 "type": "directive"333 },334 {335 "name": "ngHide",336 "href": "api/ng/directive/ngHide",337 "type": "directive"338 },339 {340 "name": "ngHref",341 "href": "api/ng/directive/ngHref",342 "type": "directive"343 },344 {345 "name": "ngIf",346 "href": "api/ng/directive/ngIf",347 "type": "directive"348 },349 {350 "name": "ngInclude",351 "href": "api/ng/directive/ngInclude",352 "type": "directive"353 },354 {355 "name": "ngInit",356 "href": "api/ng/directive/ngInit",357 "type": "directive"358 },359 {360 "name": "ngJq",361 "href": "api/ng/directive/ngJq",362 "type": "directive"363 },364 {365 "name": "ngKeydown",366 "href": "api/ng/directive/ngKeydown",367 "type": "directive"368 },369 {370 "name": "ngKeypress",371 "href": "api/ng/directive/ngKeypress",372 "type": "directive"373 },374 {375 "name": "ngKeyup",376 "href": "api/ng/directive/ngKeyup",377 "type": "directive"378 },379 {380 "name": "ngList",381 "href": "api/ng/directive/ngList",382 "type": "directive"383 },384 {385 "name": "ngMaxlength",386 "href": "api/ng/directive/ngMaxlength",387 "type": "directive"388 },389 {390 "name": "ngMinlength",391 "href": "api/ng/directive/ngMinlength",392 "type": "directive"393 },394 {395 "name": "ngModel",396 "href": "api/ng/directive/ngModel",397 "type": "directive"398 },399 {400 "name": "ngModelOptions",401 "href": "api/ng/directive/ngModelOptions",402 "type": "directive"403 },404 {405 "name": "ngMousedown",406 "href": "api/ng/directive/ngMousedown",407 "type": "directive"408 },409 {410 "name": "ngMouseenter",411 "href": "api/ng/directive/ngMouseenter",412 "type": "directive"413 },414 {415 "name": "ngMouseleave",416 "href": "api/ng/directive/ngMouseleave",417 "type": "directive"418 },419 {420 "name": "ngMousemove",421 "href": "api/ng/directive/ngMousemove",422 "type": "directive"423 },424 {425 "name": "ngMouseover",426 "href": "api/ng/directive/ngMouseover",427 "type": "directive"428 },429 {430 "name": "ngMouseup",431 "href": "api/ng/directive/ngMouseup",432 "type": "directive"433 },434 {435 "name": "ngNonBindable",436 "href": "api/ng/directive/ngNonBindable",437 "type": "directive"438 },439 {440 "name": "ngOpen",441 "href": "api/ng/directive/ngOpen",442 "type": "directive"443 },444 {445 "name": "ngOptions",446 "href": "api/ng/directive/ngOptions",447 "type": "directive"448 },449 {450 "name": "ngPaste",451 "href": "api/ng/directive/ngPaste",452 "type": "directive"453 },454 {455 "name": "ngPattern",456 "href": "api/ng/directive/ngPattern",457 "type": "directive"458 },459 {460 "name": "ngPluralize",461 "href": "api/ng/directive/ngPluralize",462 "type": "directive"463 },464 {465 "name": "ngReadonly",466 "href": "api/ng/directive/ngReadonly",467 "type": "directive"468 },469 {470 "name": "ngRepeat",471 "href": "api/ng/directive/ngRepeat",472 "type": "directive"473 },474 {475 "name": "ngRequired",476 "href": "api/ng/directive/ngRequired",477 "type": "directive"478 },479 {480 "name": "ngSelected",481 "href": "api/ng/directive/ngSelected",482 "type": "directive"483 },484 {485 "name": "ngShow",486 "href": "api/ng/directive/ngShow",487 "type": "directive"488 },489 {490 "name": "ngSrc",491 "href": "api/ng/directive/ngSrc",492 "type": "directive"493 },494 {495 "name": "ngSrcset",496 "href": "api/ng/directive/ngSrcset",497 "type": "directive"498 },499 {500 "name": "ngStyle",501 "href": "api/ng/directive/ngStyle",502 "type": "directive"503 },504 {505 "name": "ngSubmit",506 "href": "api/ng/directive/ngSubmit",507 "type": "directive"508 },509 {510 "name": "ngSwitch",511 "href": "api/ng/directive/ngSwitch",512 "type": "directive"513 },514 {515 "name": "ngTransclude",516 "href": "api/ng/directive/ngTransclude",517 "type": "directive"518 },519 {520 "name": "ngValue",521 "href": "api/ng/directive/ngValue",522 "type": "directive"523 },524 {525 "name": "script",526 "href": "api/ng/directive/script",527 "type": "directive"528 },529 {530 "name": "select",531 "href": "api/ng/directive/select",532 "type": "directive"533 },534 {535 "name": "textarea",536 "href": "api/ng/directive/textarea",537 "type": "directive"538 },539 {540 "name": "object",541 "type": "section",542 "href": "api/ng/object"543 },544 {545 "name": "angular.version",546 "href": "api/ng/object/angular.version",547 "type": "object"548 },549 {550 "name": "type",551 "type": "section",552 "href": "api/ng/type"553 },554 {555 "name": "$cacheFactory.Cache",556 "href": "api/ng/type/$cacheFactory.Cache",557 "type": "type"558 },559 {560 "name": "$compile.directive.Attributes",561 "href": "api/ng/type/$compile.directive.Attributes",562 "type": "type"563 },564 {565 "name": "$rootScope.Scope",566 "href": "api/ng/type/$rootScope.Scope",567 "type": "type"568 },569 {570 "name": "ModelOptions",571 "href": "api/ng/type/ModelOptions",572 "type": "type"573 },574 {575 "name": "angular.Module",576 "href": "api/ng/type/angular.Module",577 "type": "type"578 },579 {580 "name": "form.FormController",581 "href": "api/ng/type/form.FormController",582 "type": "type"583 },584 {585 "name": "ngModel.NgModelController",586 "href": "api/ng/type/ngModel.NgModelController",587 "type": "type"588 },589 {590 "name": "select.SelectController",591 "href": "api/ng/type/select.SelectController",592 "type": "type"593 },594 {595 "name": "provider",596 "type": "section",597 "href": "api/ng/provider"598 },599 {600 "name": "$anchorScrollProvider",601 "href": "api/ng/provider/$anchorScrollProvider",602 "type": "provider"603 },604 {605 "name": "$animateProvider",606 "href": "api/ng/provider/$animateProvider",607 "type": "provider"608 },609 {610 "name": "$compileProvider",611 "href": "api/ng/provider/$compileProvider",612 "type": "provider"613 },614 {615 "name": "$controllerProvider",616 "href": "api/ng/provider/$controllerProvider",617 "type": "provider"618 },619 {620 "name": "$filterProvider",621 "href": "api/ng/provider/$filterProvider",622 "type": "provider"623 },624 {625 "name": "$httpProvider",626 "href": "api/ng/provider/$httpProvider",627 "type": "provider"628 },629 {630 "name": "$interpolateProvider",631 "href": "api/ng/provider/$interpolateProvider",632 "type": "provider"633 },634 {635 "name": "$locationProvider",636 "href": "api/ng/provider/$locationProvider",637 "type": "provider"638 },639 {640 "name": "$logProvider",641 "href": "api/ng/provider/$logProvider",642 "type": "provider"643 },644 {645 "name": "$parseProvider",646 "href": "api/ng/provider/$parseProvider",647 "type": "provider"648 },649 {650 "name": "$qProvider",651 "href": "api/ng/provider/$qProvider",652 "type": "provider"653 },654 {655 "name": "$rootScopeProvider",656 "href": "api/ng/provider/$rootScopeProvider",657 "type": "provider"658 },659 {660 "name": "$sceDelegateProvider",661 "href": "api/ng/provider/$sceDelegateProvider",662 "type": "provider"663 },664 {665 "name": "$sceProvider",666 "href": "api/ng/provider/$sceProvider",667 "type": "provider"668 },669 {670 "name": "$templateRequestProvider",671 "href": "api/ng/provider/$templateRequestProvider",672 "type": "provider"673 },674 {675 "name": "service",676 "type": "section",677 "href": "api/ng/service"678 },679 {680 "name": "$anchorScroll",681 "href": "api/ng/service/$anchorScroll",682 "type": "service"683 },684 {685 "name": "$animate",686 "href": "api/ng/service/$animate",687 "type": "service"688 },689 {690 "name": "$animateCss",691 "href": "api/ng/service/$animateCss",692 "type": "service"693 },694 {695 "name": "$cacheFactory",696 "href": "api/ng/service/$cacheFactory",697 "type": "service"698 },699 {700 "name": "$compile",701 "href": "api/ng/service/$compile",702 "type": "service"703 },704 {705 "name": "$controller",706 "href": "api/ng/service/$controller",707 "type": "service"708 },709 {710 "name": "$document",711 "href": "api/ng/service/$document",712 "type": "service"713 },714 {715 "name": "$exceptionHandler",716 "href": "api/ng/service/$exceptionHandler",717 "type": "service"718 },719 {720 "name": "$filter",721 "href": "api/ng/service/$filter",722 "type": "service"723 },724 {725 "name": "$http",726 "href": "api/ng/service/$http",727 "type": "service"728 },729 {730 "name": "$httpBackend",731 "href": "api/ng/service/$httpBackend",732 "type": "service"733 },734 {735 "name": "$httpParamSerializer",736 "href": "api/ng/service/$httpParamSerializer",737 "type": "service"738 },739 {740 "name": "$httpParamSerializerJQLike",741 "href": "api/ng/service/$httpParamSerializerJQLike",742 "type": "service"743 },744 {745 "name": "$interpolate",746 "href": "api/ng/service/$interpolate",747 "type": "service"748 },749 {750 "name": "$interval",751 "href": "api/ng/service/$interval",752 "type": "service"753 },754 {755 "name": "$jsonpCallbacks",756 "href": "api/ng/service/$jsonpCallbacks",757 "type": "service"758 },759 {760 "name": "$locale",761 "href": "api/ng/service/$locale",762 "type": "service"763 },764 {765 "name": "$location",766 "href": "api/ng/service/$location",767 "type": "service"768 },769 {770 "name": "$log",771 "href": "api/ng/service/$log",772 "type": "service"773 },774 {775 "name": "$parse",776 "href": "api/ng/service/$parse",777 "type": "service"778 },779 {780 "name": "$q",781 "href": "api/ng/service/$q",782 "type": "service"783 },784 {785 "name": "$rootElement",786 "href": "api/ng/service/$rootElement",787 "type": "service"788 },789 {790 "name": "$rootScope",791 "href": "api/ng/service/$rootScope",792 "type": "service"793 },794 {795 "name": "$sce",796 "href": "api/ng/service/$sce",797 "type": "service"798 },799 {800 "name": "$sceDelegate",801 "href": "api/ng/service/$sceDelegate",802 "type": "service"803 },804 {805 "name": "$templateCache",806 "href": "api/ng/service/$templateCache",807 "type": "service"808 },809 {810 "name": "$templateRequest",811 "href": "api/ng/service/$templateRequest",812 "type": "service"813 },814 {815 "name": "$timeout",816 "href": "api/ng/service/$timeout",817 "type": "service"818 },819 {820 "name": "$window",821 "href": "api/ng/service/$window",822 "type": "service"823 },824 {825 "name": "$xhrFactory",826 "href": "api/ng/service/$xhrFactory",827 "type": "service"828 },829 {830 "name": "filter",831 "type": "section",832 "href": "api/ng/filter"833 },834 {835 "name": "currency",836 "href": "api/ng/filter/currency",837 "type": "filter"838 },839 {840 "name": "date",841 "href": "api/ng/filter/date",842 "type": "filter"843 },844 {845 "name": "filter",846 "href": "api/ng/filter/filter",847 "type": "filter"848 },849 {850 "name": "json",851 "href": "api/ng/filter/json",852 "type": "filter"853 },854 {855 "name": "limitTo",856 "href": "api/ng/filter/limitTo",857 "type": "filter"858 },859 {860 "name": "lowercase",861 "href": "api/ng/filter/lowercase",862 "type": "filter"863 },864 {865 "name": "number",866 "href": "api/ng/filter/number",867 "type": "filter"868 },869 {870 "name": "orderBy",871 "href": "api/ng/filter/orderBy",872 "type": "filter"873 },874 {875 "name": "uppercase",876 "href": "api/ng/filter/uppercase",877 "type": "filter"878 }879 ]880 },881 {882 "name": "auto",883 "href": "api/auto",884 "type": "group",885 "navItems": [886 {887 "name": "service",888 "type": "section",889 "href": "api/auto/service"890 },891 {892 "name": "$injector",893 "href": "api/auto/service/$injector",894 "type": "service"895 },896 {897 "name": "$provide",898 "href": "api/auto/service/$provide",899 "type": "service"900 }901 ]902 },903 {904 "name": "ngAnimate",905 "href": "api/ngAnimate",906 "type": "group",907 "navItems": [908 {909 "name": "directive",910 "type": "section",911 "href": "api/ngAnimate/directive"912 },913 {914 "name": "ngAnimateChildren",915 "href": "api/ngAnimate/directive/ngAnimateChildren",916 "type": "directive"917 },918 {919 "name": "ngAnimateSwap",920 "href": "api/ngAnimate/directive/ngAnimateSwap",921 "type": "directive"922 },923 {924 "name": "service",925 "type": "section",926 "href": "api/ngAnimate/service"927 },928 {929 "name": "$animate",930 "href": "api/ngAnimate/service/$animate",931 "type": "service"932 },933 {934 "name": "$animateCss",935 "href": "api/ngAnimate/service/$animateCss",936 "type": "service"937 }938 ]939 },940 {941 "name": "ngAria",942 "href": "api/ngAria",943 "type": "group",944 "navItems": [945 {946 "name": "provider",947 "type": "section",948 "href": "api/ngAria/provider"949 },950 {951 "name": "$ariaProvider",952 "href": "api/ngAria/provider/$ariaProvider",953 "type": "provider"954 },955 {956 "name": "service",957 "type": "section",958 "href": "api/ngAria/service"959 },960 {961 "name": "$aria",962 "href": "api/ngAria/service/$aria",963 "type": "service"964 }965 ]966 },967 {968 "name": "ngComponentRouter",969 "href": "api/ngComponentRouter",970 "type": "group",971 "navItems": [972 {973 "name": "type",974 "type": "section",975 "href": "api/ngComponentRouter/type"976 },977 {978 "name": "ChildRouter",979 "href": "api/ngComponentRouter/type/ChildRouter",980 "type": "type"981 },982 {983 "name": "ComponentInstruction",984 "href": "api/ngComponentRouter/type/ComponentInstruction",985 "type": "type"986 },987 {988 "name": "RootRouter",989 "href": "api/ngComponentRouter/type/RootRouter",990 "type": "type"991 },992 {993 "name": "RouteDefinition",994 "href": "api/ngComponentRouter/type/RouteDefinition",995 "type": "type"996 },997 {998 "name": "RouteParams",999 "href": "api/ngComponentRouter/type/RouteParams",1000 "type": "type"1001 },1002 {1003 "name": "Router",1004 "href": "api/ngComponentRouter/type/Router",1005 "type": "type"1006 },1007 {1008 "name": "directive",1009 "type": "section",1010 "href": "api/ngComponentRouter/directive"1011 },1012 {1013 "name": "ngOutlet",1014 "href": "api/ngComponentRouter/directive/ngOutlet",1015 "type": "directive"1016 },1017 {1018 "name": "service",1019 "type": "section",1020 "href": "api/ngComponentRouter/service"1021 },1022 {1023 "name": "$rootRouter",1024 "href": "api/ngComponentRouter/service/$rootRouter",1025 "type": "service"1026 },1027 {1028 "name": "$routerRootComponent",1029 "href": "api/ngComponentRouter/service/$routerRootComponent",1030 "type": "service"1031 }1032 ]1033 },1034 {1035 "name": "ngCookies",1036 "href": "api/ngCookies",1037 "type": "group",1038 "navItems": [1039 {1040 "name": "provider",1041 "type": "section",1042 "href": "api/ngCookies/provider"1043 },1044 {1045 "name": "$cookiesProvider",1046 "href": "api/ngCookies/provider/$cookiesProvider",1047 "type": "provider"1048 },1049 {1050 "name": "service",1051 "type": "section",1052 "href": "api/ngCookies/service"1053 },1054 {1055 "name": "$cookieStore",1056 "href": "api/ngCookies/service/$cookieStore",1057 "type": "service"1058 },1059 {1060 "name": "$cookies",1061 "href": "api/ngCookies/service/$cookies",1062 "type": "service"1063 }1064 ]1065 },1066 {1067 "name": "ngMessageFormat",1068 "href": "api/ngMessageFormat",1069 "type": "group",1070 "navItems": []1071 },1072 {1073 "name": "ngMessages",1074 "href": "api/ngMessages",1075 "type": "group",1076 "navItems": [1077 {1078 "name": "directive",1079 "type": "section",1080 "href": "api/ngMessages/directive"1081 },1082 {1083 "name": "ngMessage",1084 "href": "api/ngMessages/directive/ngMessage",1085 "type": "directive"1086 },1087 {1088 "name": "ngMessageExp",1089 "href": "api/ngMessages/directive/ngMessageExp",1090 "type": "directive"1091 },1092 {1093 "name": "ngMessages",1094 "href": "api/ngMessages/directive/ngMessages",1095 "type": "directive"1096 },1097 {1098 "name": "ngMessagesInclude",1099 "href": "api/ngMessages/directive/ngMessagesInclude",1100 "type": "directive"1101 }1102 ]1103 },1104 {1105 "name": "ngMock",1106 "href": "api/ngMock",1107 "type": "group",1108 "navItems": [1109 {1110 "name": "object",1111 "type": "section",1112 "href": "api/ngMock/object"1113 },1114 {1115 "name": "angular.mock",1116 "href": "api/ngMock/object/angular.mock",1117 "type": "object"1118 },1119 {1120 "name": "provider",1121 "type": "section",1122 "href": "api/ngMock/provider"1123 },1124 {1125 "name": "$exceptionHandlerProvider",1126 "href": "api/ngMock/provider/$exceptionHandlerProvider",1127 "type": "provider"1128 },1129 {1130 "name": "service",1131 "type": "section",1132 "href": "api/ngMock/service"1133 },1134 {1135 "name": "$animate",1136 "href": "api/ngMock/service/$animate",1137 "type": "service"1138 },1139 {1140 "name": "$componentController",1141 "href": "api/ngMock/service/$componentController",1142 "type": "service"1143 },1144 {1145 "name": "$controller",1146 "href": "api/ngMock/service/$controller",1147 "type": "service"1148 },1149 {1150 "name": "$exceptionHandler",1151 "href": "api/ngMock/service/$exceptionHandler",1152 "type": "service"1153 },1154 {1155 "name": "$httpBackend",1156 "href": "api/ngMock/service/$httpBackend",1157 "type": "service"1158 },1159 {1160 "name": "$interval",1161 "href": "api/ngMock/service/$interval",1162 "type": "service"1163 },1164 {1165 "name": "$log",1166 "href": "api/ngMock/service/$log",1167 "type": "service"1168 },1169 {1170 "name": "$timeout",1171 "href": "api/ngMock/service/$timeout",1172 "type": "service"1173 },1174 {1175 "name": "type",1176 "type": "section",1177 "href": "api/ngMock/type"1178 },1179 {1180 "name": "$rootScope.Scope",1181 "href": "api/ngMock/type/$rootScope.Scope",1182 "type": "type"1183 },1184 {1185 "name": "angular.mock.TzDate",1186 "href": "api/ngMock/type/angular.mock.TzDate",1187 "type": "type"1188 },1189 {1190 "name": "function",1191 "type": "section",1192 "href": "api/ngMock/function"1193 },1194 {1195 "name": "angular.mock.dump",1196 "href": "api/ngMock/function/angular.mock.dump",1197 "type": "function"1198 },1199 {1200 "name": "angular.mock.inject",1201 "href": "api/ngMock/function/angular.mock.inject",1202 "type": "function"1203 },1204 {1205 "name": "angular.mock.module",1206 "href": "api/ngMock/function/angular.mock.module",1207 "type": "function"1208 },1209 {1210 "name": "angular.mock.module.sharedInjector",1211 "href": "api/ngMock/function/angular.mock.module.sharedInjector",1212 "type": "function"1213 }1214 ]1215 },1216 {1217 "name": "ngMockE2E",1218 "href": "api/ngMockE2E",1219 "type": "group",1220 "navItems": [1221 {1222 "name": "service",1223 "type": "section",1224 "href": "api/ngMockE2E/service"1225 },1226 {1227 "name": "$httpBackend",1228 "href": "api/ngMockE2E/service/$httpBackend",1229 "type": "service"1230 }1231 ]1232 },1233 {1234 "name": "ngParseExt",1235 "href": "api/ngParseExt",1236 "type": "group",1237 "navItems": []1238 },1239 {1240 "name": "ngResource",1241 "href": "api/ngResource",1242 "type": "group",1243 "navItems": [1244 {1245 "name": "provider",1246 "type": "section",1247 "href": "api/ngResource/provider"1248 },1249 {1250 "name": "$resourceProvider",1251 "href": "api/ngResource/provider/$resourceProvider",1252 "type": "provider"1253 },1254 {1255 "name": "service",1256 "type": "section",1257 "href": "api/ngResource/service"1258 },1259 {1260 "name": "$resource",1261 "href": "api/ngResource/service/$resource",1262 "type": "service"1263 }1264 ]1265 },1266 {1267 "name": "ngRoute",1268 "href": "api/ngRoute",1269 "type": "group",1270 "navItems": [1271 {1272 "name": "directive",1273 "type": "section",1274 "href": "api/ngRoute/directive"1275 },1276 {1277 "name": "ngView",1278 "href": "api/ngRoute/directive/ngView",1279 "type": "directive"1280 },1281 {1282 "name": "provider",1283 "type": "section",1284 "href": "api/ngRoute/provider"1285 },1286 {1287 "name": "$routeProvider",1288 "href": "api/ngRoute/provider/$routeProvider",1289 "type": "provider"1290 },1291 {1292 "name": "service",1293 "type": "section",1294 "href": "api/ngRoute/service"1295 },1296 {1297 "name": "$route",1298 "href": "api/ngRoute/service/$route",1299 "type": "service"1300 },1301 {1302 "name": "$routeParams",1303 "href": "api/ngRoute/service/$routeParams",1304 "type": "service"1305 }1306 ]1307 },1308 {1309 "name": "ngSanitize",1310 "href": "api/ngSanitize",1311 "type": "group",1312 "navItems": [1313 {1314 "name": "filter",1315 "type": "section",1316 "href": "api/ngSanitize/filter"1317 },1318 {1319 "name": "linky",1320 "href": "api/ngSanitize/filter/linky",1321 "type": "filter"1322 },1323 {1324 "name": "service",1325 "type": "section",1326 "href": "api/ngSanitize/service"1327 },1328 {1329 "name": "$sanitize",1330 "href": "api/ngSanitize/service/$sanitize",1331 "type": "service"1332 },1333 {1334 "name": "provider",1335 "type": "section",1336 "href": "api/ngSanitize/provider"1337 },1338 {1339 "name": "$sanitizeProvider",1340 "href": "api/ngSanitize/provider/$sanitizeProvider",1341 "type": "provider"1342 }1343 ]1344 },1345 {1346 "name": "ngTouch",1347 "href": "api/ngTouch",1348 "type": "group",1349 "navItems": [1350 {1351 "name": "directive",1352 "type": "section",1353 "href": "api/ngTouch/directive"1354 },1355 {1356 "name": "ngClick",1357 "href": "api/ngTouch/directive/ngClick",1358 "type": "directive"1359 },1360 {1361 "name": "ngSwipeLeft",1362 "href": "api/ngTouch/directive/ngSwipeLeft",1363 "type": "directive"1364 },1365 {1366 "name": "ngSwipeRight",1367 "href": "api/ngTouch/directive/ngSwipeRight",1368 "type": "directive"1369 },1370 {1371 "name": "service",1372 "type": "section",1373 "href": "api/ngTouch/service"1374 },1375 {1376 "name": "$swipe",1377 "href": "api/ngTouch/service/$swipe",1378 "type": "service"1379 },1380 {1381 "name": "$touch",1382 "href": "api/ngTouch/service/$touch",1383 "type": "service"1384 },1385 {1386 "name": "provider",1387 "type": "section",1388 "href": "api/ngTouch/provider"1389 },1390 {1391 "name": "$touchProvider",1392 "href": "api/ngTouch/provider/$touchProvider",1393 "type": "provider"1394 }1395 ]1396 }1397 ]1398 },1399 "error": {1400 "id": "error",1401 "name": "Error Reference",1402 "navGroups": [1403 {1404 "name": "Error Reference",1405 "type": "group",1406 "href": "error",1407 "navItems": [1408 {1409 "name": "$animate",1410 "href": "error/$animate",1411 "type": "section"1412 },1413 {1414 "name": "nongcls",1415 "href": "error/$animate/nongcls",1416 "type": "error"1417 },1418 {1419 "name": "notcsel",1420 "href": "error/$animate/notcsel",1421 "type": "error"1422 },1423 {1424 "name": "$cacheFactory",1425 "href": "error/$cacheFactory",1426 "type": "section"1427 },1428 {1429 "name": "iid",1430 "href": "error/$cacheFactory/iid",1431 "type": "error"1432 },1433 {1434 "name": "$compile",1435 "href": "error/$compile",1436 "type": "section"1437 },1438 {1439 "name": "baddir",1440 "href": "error/$compile/baddir",1441 "type": "error"1442 },1443 {1444 "name": "badrestrict",1445 "href": "error/$compile/badrestrict",1446 "type": "error"1447 },1448 {1449 "name": "ctreq",1450 "href": "error/$compile/ctreq",1451 "type": "error"1452 },1453 {1454 "name": "infchng",1455 "href": "error/$compile/infchng",1456 "type": "error"1457 },1458 {1459 "name": "iscp",1460 "href": "error/$compile/iscp",1461 "type": "error"1462 },1463 {1464 "name": "missingattr",1465 "href": "error/$compile/missingattr",1466 "type": "error"1467 },1468 {1469 "name": "multidir",1470 "href": "error/$compile/multidir",1471 "type": "error"1472 },1473 {1474 "name": "multilink",1475 "href": "error/$compile/multilink",1476 "type": "error"1477 },1478 {1479 "name": "noctrl",1480 "href": "error/$compile/noctrl",1481 "type": "error"1482 },1483 {1484 "name": "nodomevents",1485 "href": "error/$compile/nodomevents",1486 "type": "error"1487 },1488 {1489 "name": "nonassign",1490 "href": "error/$compile/nonassign",1491 "type": "error"1492 },1493 {1494 "name": "noslot",1495 "href": "error/$compile/noslot",1496 "type": "error"1497 },1498 {1499 "name": "reqslot",1500 "href": "error/$compile/reqslot",1501 "type": "error"1502 },1503 {1504 "name": "selmulti",1505 "href": "error/$compile/selmulti",1506 "type": "error"1507 },1508 {1509 "name": "tpload",1510 "href": "error/$compile/tpload",1511 "type": "error"1512 },1513 {1514 "name": "tplrt",1515 "href": "error/$compile/tplrt",1516 "type": "error"1517 },1518 {1519 "name": "uterdir",1520 "href": "error/$compile/uterdir",1521 "type": "error"1522 },1523 {1524 "name": "$controller",1525 "href": "error/$controller",1526 "type": "section"1527 },1528 {1529 "name": "ctrlfmt",1530 "href": "error/$controller/ctrlfmt",1531 "type": "error"1532 },1533 {1534 "name": "ctrlreg",1535 "href": "error/$controller/ctrlreg",1536 "type": "error"1537 },1538 {1539 "name": "noscp",1540 "href": "error/$controller/noscp",1541 "type": "error"1542 },1543 {1544 "name": "$http",1545 "href": "error/$http",1546 "type": "section"1547 },1548 {1549 "name": "baddata",1550 "href": "error/$http/baddata",1551 "type": "error"1552 },1553 {1554 "name": "badjsonp",1555 "href": "error/$http/badjsonp",1556 "type": "error"1557 },1558 {1559 "name": "badreq",1560 "href": "error/$http/badreq",1561 "type": "error"1562 },1563 {1564 "name": "$injector",1565 "href": "error/$injector",1566 "type": "section"1567 },1568 {1569 "name": "cdep",1570 "href": "error/$injector/cdep",1571 "type": "error"1572 },1573 {1574 "name": "itkn",1575 "href": "error/$injector/itkn",1576 "type": "error"1577 },1578 {1579 "name": "modulerr",1580 "href": "error/$injector/modulerr",1581 "type": "error"1582 },1583 {1584 "name": "nomod",1585 "href": "error/$injector/nomod",1586 "type": "error"1587 },1588 {1589 "name": "pget",1590 "href": "error/$injector/pget",1591 "type": "error"1592 },1593 {1594 "name": "strictdi",1595 "href": "error/$injector/strictdi",1596 "type": "error"1597 },1598 {1599 "name": "undef",1600 "href": "error/$injector/undef",1601 "type": "error"1602 },1603 {1604 "name": "unpr",1605 "href": "error/$injector/unpr",1606 "type": "error"1607 },1608 {1609 "name": "$interpolate",1610 "href": "error/$interpolate",1611 "type": "section"1612 },1613 {1614 "name": "badexpr",1615 "href": "error/$interpolate/badexpr",1616 "type": "error"1617 },1618 {1619 "name": "dupvalue",1620 "href": "error/$interpolate/dupvalue",1621 "type": "error"1622 },1623 {1624 "name": "interr",1625 "href": "error/$interpolate/interr",1626 "type": "error"1627 },1628 {1629 "name": "logicbug",1630 "href": "error/$interpolate/logicbug",1631 "type": "error"1632 },1633 {1634 "name": "nochgmustache",1635 "href": "error/$interpolate/nochgmustache",1636 "type": "error"1637 },1638 {1639 "name": "noconcat",1640 "href": "error/$interpolate/noconcat",1641 "type": "error"1642 },1643 {1644 "name": "reqarg",1645 "href": "error/$interpolate/reqarg",1646 "type": "error"1647 },1648 {1649 "name": "reqcomma",1650 "href": "error/$interpolate/reqcomma",1651 "type": "error"1652 },1653 {1654 "name": "reqendbrace",1655 "href": "error/$interpolate/reqendbrace",1656 "type": "error"1657 },1658 {1659 "name": "reqendinterp",1660 "href": "error/$interpolate/reqendinterp",1661 "type": "error"1662 },1663 {1664 "name": "reqopenbrace",1665 "href": "error/$interpolate/reqopenbrace",1666 "type": "error"1667 },1668 {1669 "name": "reqother",1670 "href": "error/$interpolate/reqother",1671 "type": "error"1672 },1673 {1674 "name": "unknarg",1675 "href": "error/$interpolate/unknarg",1676 "type": "error"1677 },1678 {1679 "name": "unsafe",1680 "href": "error/$interpolate/unsafe",1681 "type": "error"1682 },1683 {1684 "name": "untermstr",1685 "href": "error/$interpolate/untermstr",1686 "type": "error"1687 },1688 {1689 "name": "wantstring",1690 "href": "error/$interpolate/wantstring",1691 "type": "error"1692 },1693 {1694 "name": "$location",1695 "href": "error/$location",1696 "type": "section"1697 },1698 {1699 "name": "badpath",1700 "href": "error/$location/badpath",1701 "type": "error"1702 },1703 {1704 "name": "ipthprfx",1705 "href": "error/$location/ipthprfx",1706 "type": "error"1707 },1708 {1709 "name": "isrcharg",1710 "href": "error/$location/isrcharg",1711 "type": "error"1712 },1713 {1714 "name": "nobase",1715 "href": "error/$location/nobase",1716 "type": "error"1717 },1718 {1719 "name": "nostate",1720 "href": "error/$location/nostate",1721 "type": "error"1722 },1723 {1724 "name": "$parse",1725 "href": "error/$parse",1726 "type": "section"1727 },1728 {1729 "name": "lexerr",1730 "href": "error/$parse/lexerr",1731 "type": "error"1732 },1733 {1734 "name": "syntax",1735 "href": "error/$parse/syntax",1736 "type": "error"1737 },1738 {1739 "name": "ueoe",1740 "href": "error/$parse/ueoe",1741 "type": "error"1742 },1743 {1744 "name": "$q",1745 "href": "error/$q",1746 "type": "section"1747 },1748 {1749 "name": "norslvr",1750 "href": "error/$q/norslvr",1751 "type": "error"1752 },1753 {1754 "name": "qcycle",1755 "href": "error/$q/qcycle",1756 "type": "error"1757 },1758 {1759 "name": "$resource",1760 "href": "error/$resource",1761 "type": "section"1762 },1763 {1764 "name": "badargs",1765 "href": "error/$resource/badargs",1766 "type": "error"1767 },1768 {1769 "name": "badcfg",1770 "href": "error/$resource/badcfg",1771 "type": "error"1772 },1773 {1774 "name": "badmember",1775 "href": "error/$resource/badmember",1776 "type": "error"1777 },1778 {1779 "name": "badname",1780 "href": "error/$resource/badname",1781 "type": "error"1782 },1783 {1784 "name": "$rootScope",1785 "href": "error/$rootScope",1786 "type": "section"1787 },1788 {1789 "name": "infdig",1790 "href": "error/$rootScope/infdig",1791 "type": "error"1792 },1793 {1794 "name": "inprog",1795 "href": "error/$rootScope/inprog",1796 "type": "error"1797 },1798 {1799 "name": "$sanitize",1800 "href": "error/$sanitize",1801 "type": "section"1802 },1803 {1804 "name": "elclob",1805 "href": "error/$sanitize/elclob",1806 "type": "error"1807 },1808 {1809 "name": "noinert",1810 "href": "error/$sanitize/noinert",1811 "type": "error"1812 },1813 {1814 "name": "uinput",1815 "href": "error/$sanitize/uinput",1816 "type": "error"1817 },1818 {1819 "name": "$sce",1820 "href": "error/$sce",1821 "type": "section"1822 },1823 {1824 "name": "icontext",1825 "href": "error/$sce/icontext",1826 "type": "error"1827 },1828 {1829 "name": "iequirks",1830 "href": "error/$sce/iequirks",1831 "type": "error"1832 },1833 {1834 "name": "imatcher",1835 "href": "error/$sce/imatcher",1836 "type": "error"1837 },1838 {1839 "name": "insecurl",1840 "href": "error/$sce/insecurl",1841 "type": "error"1842 },1843 {1844 "name": "itype",1845 "href": "error/$sce/itype",1846 "type": "error"1847 },1848 {1849 "name": "iwcard",1850 "href": "error/$sce/iwcard",1851 "type": "error"1852 },1853 {1854 "name": "unsafe",1855 "href": "error/$sce/unsafe",1856 "type": "error"1857 },1858 {1859 "name": "filter",1860 "href": "error/filter",1861 "type": "section"1862 },1863 {1864 "name": "notarray",1865 "href": "error/filter/notarray",1866 "type": "error"1867 },1868 {1869 "name": "jqLite",1870 "href": "error/jqLite",1871 "type": "section"1872 },1873 {1874 "name": "nosel",1875 "href": "error/jqLite/nosel",1876 "type": "error"1877 },1878 {1879 "name": "offargs",1880 "href": "error/jqLite/offargs",1881 "type": "error"1882 },1883 {1884 "name": "onargs",1885 "href": "error/jqLite/onargs",1886 "type": "error"1887 },1888 {1889 "name": "linky",1890 "href": "error/linky",1891 "type": "section"1892 },1893 {1894 "name": "notstring",1895 "href": "error/linky/notstring",1896 "type": "error"1897 },1898 {1899 "name": "ng",1900 "href": "error/ng",1901 "type": "section"1902 },1903 {1904 "name": "aobj",1905 "href": "error/ng/aobj",1906 "type": "error"1907 },1908 {1909 "name": "areq",1910 "href": "error/ng/areq",1911 "type": "error"1912 },1913 {1914 "name": "badname",1915 "href": "error/ng/badname",1916 "type": "error"1917 },1918 {1919 "name": "btstrpd",1920 "href": "error/ng/btstrpd",1921 "type": "error"1922 },1923 {1924 "name": "cpi",1925 "href": "error/ng/cpi",1926 "type": "error"1927 },1928 {1929 "name": "cpta",1930 "href": "error/ng/cpta",1931 "type": "error"1932 },1933 {1934 "name": "cpws",1935 "href": "error/ng/cpws",1936 "type": "error"1937 },1938 {1939 "name": "test",1940 "href": "error/ng/test",1941 "type": "error"1942 },1943 {1944 "name": "ngModel",1945 "href": "error/ngModel",1946 "type": "section"1947 },1948 {1949 "name": "constexpr",1950 "href": "error/ngModel/constexpr",1951 "type": "error"1952 },1953 {1954 "name": "datefmt",1955 "href": "error/ngModel/datefmt",1956 "type": "error"1957 },1958 {1959 "name": "nonassign",1960 "href": "error/ngModel/nonassign",1961 "type": "error"1962 },1963 {1964 "name": "nopromise",1965 "href": "error/ngModel/nopromise",1966 "type": "error"1967 },1968 {1969 "name": "numfmt",1970 "href": "error/ngModel/numfmt",1971 "type": "error"1972 },1973 {1974 "name": "ngOptions",1975 "href": "error/ngOptions",1976 "type": "section"1977 },1978 {1979 "name": "iexp",1980 "href": "error/ngOptions/iexp",1981 "type": "error"1982 },1983 {1984 "name": "ngPattern",1985 "href": "error/ngPattern",1986 "type": "section"1987 },1988 {1989 "name": "noregexp",1990 "href": "error/ngPattern/noregexp",1991 "type": "error"1992 },1993 {1994 "name": "ngRepeat",1995 "href": "error/ngRepeat",1996 "type": "section"1997 },1998 {1999 "name": "badident",2000 "href": "error/ngRepeat/badident",2001 "type": "error"2002 },2003 {2004 "name": "dupes",2005 "href": "error/ngRepeat/dupes",2006 "type": "error"2007 },2008 {2009 "name": "iexp",2010 "href": "error/ngRepeat/iexp",2011 "type": "error"2012 },2013 {2014 "name": "iidexp",2015 "href": "error/ngRepeat/iidexp",2016 "type": "error"2017 },2018 {2019 "name": "ngTransclude",2020 "href": "error/ngTransclude",2021 "type": "section"2022 },2023 {2024 "name": "orphan",2025 "href": "error/ngTransclude/orphan",2026 "type": "error"2027 },2028 {2029 "name": "orderBy",2030 "href": "error/orderBy",2031 "type": "section"2032 },2033 {2034 "name": "notarray",2035 "href": "error/orderBy/notarray",2036 "type": "error"2037 }2038 ]2039 }2040 ]2041 },2042 "guide": {2043 "id": "guide",2044 "name": "Developer Guide",2045 "navGroups": [2046 {2047 "name": "Developer Guide",2048 "type": "group",2049 "href": "guide",2050 "navItems": [2051 {2052 "name": "Introduction",2053 "href": "guide/introduction",2054 "type": "page"2055 },2056 {2057 "name": "External Resources",2058 "href": "guide/external-resources",2059 "type": "page"2060 },2061 {2062 "name": "Conceptual Overview",2063 "href": "guide/concepts",2064 "type": "page"2065 },2066 {2067 "name": "Data Binding",2068 "href": "guide/databinding",2069 "type": "page"2070 },2071 {2072 "name": "Controllers",2073 "href": "guide/controller",2074 "type": "page"2075 },2076 {2077 "name": "Services",2078 "href": "guide/services",2079 "type": "page"2080 },2081 {2082 "name": "Scopes",2083 "href": "guide/scope",2084 "type": "page"2085 },2086 {2087 "name": "Dependency Injection",2088 "href": "guide/di",2089 "type": "page"2090 },2091 {2092 "name": "Templates",2093 "href": "guide/templates",2094 "type": "page"2095 },2096 {2097 "name": "Expressions",2098 "href": "guide/expression",2099 "type": "page"2100 },2101 {2102 "name": "Interpolation",2103 "href": "guide/interpolation",2104 "type": "page"2105 },2106 {2107 "name": "Filters",2108 "href": "guide/filter",2109 "type": "page"2110 },2111 {2112 "name": "Forms",2113 "href": "guide/forms",2114 "type": "page"2115 },2116 {2117 "name": "Directives",2118 "href": "guide/directive",2119 "type": "page"2120 },2121 {2122 "name": "Components",2123 "href": "guide/component",2124 "type": "page"2125 },2126 {2127 "name": "Component Router",2128 "href": "guide/component-router",2129 "type": "page"2130 },2131 {2132 "name": "Animations",2133 "href": "guide/animations",2134 "type": "page"2135 },2136 {2137 "name": "Modules",2138 "href": "guide/module",2139 "type": "page"2140 },2141 {2142 "name": "HTML Compiler",2143 "href": "guide/compiler",2144 "type": "page"2145 },2146 {2147 "name": "Providers",2148 "href": "guide/providers",2149 "type": "page"2150 },2151 {2152 "name": "Decorators",2153 "href": "guide/decorators",2154 "type": "page"2155 },2156 {2157 "name": "Bootstrap",2158 "href": "guide/bootstrap",2159 "type": "page"2160 },2161 {2162 "name": "Unit Testing",2163 "href": "guide/unit-testing",2164 "type": "page"2165 },2166 {2167 "name": "E2E Testing",2168 "href": "guide/e2e-testing",2169 "type": "page"2170 },2171 {2172 "name": "Using $location",2173 "href": "guide/$location",2174 "type": "page"2175 },2176 {2177 "name": "Working With CSS",2178 "href": "guide/css-styling",2179 "type": "page"2180 },2181 {2182 "name": "i18n and l10n",2183 "href": "guide/i18n",2184 "type": "page"2185 },2186 {2187 "name": "Security",2188 "href": "guide/security",2189 "type": "page"2190 },2191 {2192 "name": "Accessibility",2193 "href": "guide/accessibility",2194 "type": "page"2195 },2196 {2197 "name": "Internet Explorer Compatibility",2198 "href": "guide/ie",2199 "type": "page"2200 },2201 {2202 "name": "Running in Production",2203 "href": "guide/production",2204 "type": "page"2205 },2206 {2207 "name": "Migrating from Previous Versions",2208 "href": "guide/migration",2209 "type": "page"2210 }2211 ]2212 }2213 ]2214 },2215 "misc": {2216 "id": "misc",2217 "name": "Miscellaneous",2218 "navGroups": [2219 {2220 "name": "Miscellaneous",2221 "type": "group",2222 "href": "misc",2223 "navItems": [2224 {2225 "name": "Develop",2226 "href": "misc/contribute",2227 "type": "page"2228 },2229 {2230 "name": "Downloading",2231 "href": "misc/downloading",2232 "type": "page"2233 },2234 {2235 "name": "FAQ",2236 "href": "misc/faq",2237 "type": "page"2238 },2239 {2240 "name": "Getting Started",2241 "href": "misc/started",2242 "type": "page"2243 }2244 ]2245 }2246 ]2247 },2248 "tutorial": {2249 "id": "tutorial",2250 "name": "Tutorial",2251 "navGroups": [2252 {2253 "name": "Tutorial",2254 "type": "group",2255 "href": "tutorial",2256 "navItems": [2257 {2258 "name": "0 - Bootstrapping",2259 "step": 0,2260 "href": "tutorial/step_00",2261 "type": "tutorial"2262 },2263 {2264 "name": "1 - Static Template",2265 "step": 1,2266 "href": "tutorial/step_01",2267 "type": "tutorial"2268 },2269 {2270 "name": "2 - Angular Templates",2271 "step": 2,2272 "href": "tutorial/step_02",2273 "type": "tutorial"2274 },2275 {2276 "name": "3 - Components",2277 "step": 3,2278 "href": "tutorial/step_03",2279 "type": "tutorial"2280 },2281 {2282 "name": "4 - Directory and File Organization",2283 "step": 4,2284 "href": "tutorial/step_04",2285 "type": "tutorial"2286 },2287 {2288 "name": "5 - Filtering Repeaters",2289 "step": 5,2290 "href": "tutorial/step_05",2291 "type": "tutorial"2292 },2293 {2294 "name": "6 - Two-way Data Binding",2295 "step": 6,2296 "href": "tutorial/step_06",2297 "type": "tutorial"2298 },2299 {2300 "name": "7 - XHR & Dependency Injection",2301 "step": 7,2302 "href": "tutorial/step_07",2303 "type": "tutorial"2304 },2305 {2306 "name": "8 - Templating Links & Images",2307 "step": 8,2308 "href": "tutorial/step_08",2309 "type": "tutorial"2310 },2311 {2312 "name": "9 - Routing & Multiple Views",2313 "step": 9,2314 "href": "tutorial/step_09",2315 "type": "tutorial"2316 },2317 {2318 "name": "10 - More Templating",2319 "step": 10,2320 "href": "tutorial/step_10",2321 "type": "tutorial"2322 },2323 {2324 "name": "11 - Custom Filters",2325 "step": 11,2326 "href": "tutorial/step_11",2327 "type": "tutorial"2328 },2329 {2330 "name": "12 - Event Handlers",2331 "step": 12,2332 "href": "tutorial/step_12",2333 "type": "tutorial"2334 },2335 {2336 "name": "13 - REST and Custom Services",2337 "step": 13,2338 "href": "tutorial/step_13",2339 "type": "tutorial"2340 },2341 {2342 "name": "14 - Animations",2343 "step": 14,2344 "href": "tutorial/step_14",2345 "type": "tutorial"2346 },2347 {2348 "name": "The End",2349 "step": 99,2350 "href": "tutorial/the_end",2351 "type": "tutorial"2352 }2353 ]2354 }2355 ]2356 }...
full_info.py
Source:full_info.py
1import requests2import pandas as pd3import numpy as np4import re5import time6cities = ''' <section><p><b>ÐдÑÐ³ÐµÑ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/1/24/">Ðайкоп</a></li><li><a href="/1/372/">ЯблоновÑкий</a></li></ul></section><section><p><b>ÐлÑай РеÑпÑблика</b></p><ul class="cities"><li><a href="/4/503/">ÐоÑно-ÐлÑайÑк</a></li></ul></section><section><p><b>ÐлÑайÑкий кÑай</b></p><ul class="cities"><li><a href="/22/106/">ÐаÑнаÑл</a></li><li><a href="/22/511/">ÐийÑк</a></li><li><a href="/22/459/">Ð ÑбÑовÑк</a></li></ul></section><section><p><b>ÐмÑÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/28/516/">ÐлаговеÑенÑк</a></li><li><a href="/28/322/">СвободнÑй</a></li></ul></section><section><p><b>ÐÑÑ
ангелÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/29/1/">ÐÑÑ
ангелÑÑк</a></li><li><a href="/29/426/">СевеÑодвинÑк</a></li></ul></section><section><p><b>ÐÑÑÑаÑ
анÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/30/2/">ÐÑÑÑаÑ
анÑ</a></li><li><a href="/30/275/">ÐÑ
ÑÑбинÑк</a></li><li><a href="/30/206/">ÐнаменÑк</a></li></ul></section><section><p><b>ÐаÑкоÑÑоÑÑан РеÑпÑблика</b></p><ul class="cities"><li><a href="/2/54/">УÑа</a></li><li><a href="/2/292/">ÐелоÑеÑк</a></li><li><a href="/2/509/">ÐиÑÑк</a></li><li><a href="/2/299/">ÐÑимбай</a></li><li><a href="/2/294/">ÐÑмеÑÑаÑ</a></li><li><a href="/2/332/">ÐелеÑз</a></li><li><a href="/2/96/">ÐеÑÑекамÑк</a></li><li><a href="/2/73/">Сибай</a></li><li><a href="/2/97/">СÑеÑлиÑамак</a></li></ul></section><section><p><b>ÐелгоÑодÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/31/3/">ÐелгоÑод</a></li><li><a href="/31/512/">ÐайÑкий</a></li><li><a href="/31/437/">СÑаÑÑй ÐÑкол</a></li></ul></section><section><p><b>ÐÑÑнÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/32/4/">ÐÑÑнÑк</a></li><li><a href="/32/2273/">Ðокино</a></li><li><a href="/32/404/">ÐовозÑбков</a></li><li><a href="/32/333/">УнеÑа</a></li></ul></section><section><p><b>ÐÑÑÑÑÐ¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/3/141/">Улан-УдÑ</a></li></ul></section><section><p><b>ÐладимиÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/33/7/">ÐладимиÑ</a></li><li><a href="/33/490/">ÐовÑов</a></li><li><a href="/33/2249/">ÐÑÑеÑа</a></li><li><a href="/33/94/">ÐÑÑом</a></li><li><a href="/33/203/">ÐокÑов</a></li></ul></section><section><p><b>ÐолгогÑадÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/34/8/">ÐолгогÑад</a></li><li><a href="/34/416/">ÐолжÑкий</a></li><li><a href="/34/430/">ÐамÑÑин</a></li></ul></section><section><p><b>ÐологодÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/35/9/">Ðологда</a></li><li><a href="/35/136/">ЧеÑеповеÑ</a></li></ul></section><section><p><b>ÐоÑонежÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/36/10/">ÐоÑонеж</a></li><li><a href="/36/508/">ÐоÑиÑоглебÑк</a></li><li><a href="/36/364/">РоÑÑоÑÑ</a></li></ul></section><section><p><b>ÐагеÑÑан РеÑпÑблика</b></p><ul class="cities"><li><a href="/5/25/">ÐаÑ
аÑкала</a></li><li><a href="/5/315/">ÐÑйнакÑк</a></li><li><a href="/5/502/">ÐеÑбенÑ</a></li><li><a href="/5/316/">ÐзбеÑбаÑ</a></li><li><a href="/5/317/">ÐаÑпийÑк</a></li><li><a href="/5/403/">ÐизлÑÑ</a></li><li><a href="/5/425/">ХаÑавÑÑÑ</a></li><li><a href="/5/569/">ЧиÑкей</a></li></ul></section><section><p><b>ÐвÑейÑÐºÐ°Ñ ÐÐ</b></p><ul class="cities"><li><a href="/79/510/">ÐиÑобиджан</a></li></ul></section><section><p><b>ÐабайкалÑÑкий кÑай</b></p><ul class="cities"><li><a href="/75/60/">ЧиÑа</a></li></ul></section><section><p><b>ÐвановÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/37/12/">Ðваново</a></li><li><a href="/37/464/">ШÑÑ</a></li></ul></section><section><p><b>ÐнгÑÑеÑÐ¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/6/2283/">ÐагаÑ</a></li><li><a href="/6/494/">ÐазÑанÑ</a></li></ul></section><section><p><b>ÐÑкÑÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/38/13/">ÐÑкÑÑÑк</a></li><li><a href="/38/515/">ÐнгаÑÑк</a></li><li><a href="/38/507/">ÐÑаÑÑк</a></li><li><a href="/38/348/">УÑÑÑ-ÐлимÑк</a></li></ul></section><section><p><b>ÐабаÑдино-ÐалкаÑиÑ</b></p><ul class="cities"><li><a href="/7/29/">ÐалÑÑик</a></li></ul></section><section><p><b>ÐалинингÑадÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/39/15/">ÐалинингÑад</a></li><li><a href="/39/442/">ÐолеÑÑк</a></li></ul></section><section><p><b>ÐалмÑÐºÐ¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/8/61/">ÐлиÑÑа</a></li></ul></section><section><p><b>ÐалÑжÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/40/16/">ÐалÑга</a></li><li><a href="/40/138/">ÐбнинÑк</a></li></ul></section><section><p><b>ÐамÑаÑÑкий кÑай</b></p><ul class="cities"><li><a href="/41/38/">ÐеÑÑопавловÑк-ÐамÑаÑÑкий</a></li></ul></section><section><p><b>ÐаÑаÑаево-ЧеÑкеÑÑиÑ</b></p><ul class="cities"><li><a href="/9/59/">ЧеÑкеÑÑк</a></li><li><a href="/9/492/">ÐаÑаÑаевÑк</a></li></ul></section><section><p><b>ÐаÑÐµÐ»Ð¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/10/491/">ÐеÑÑозаводÑк</a></li></ul></section><section><p><b>ÐемеÑовÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/42/17/">ÐемеÑово</a></li><li><a href="/42/440/">Ðелово</a></li><li><a href="/42/408/">ÐеждÑÑеÑенÑк</a></li><li><a href="/42/92/">ÐовокÑзнеÑк</a></li><li><a href="/42/99/">ÐÑокопÑевÑк</a></li><li><a href="/42/434/">ЮÑга</a></li></ul></section><section><p><b>ÐиÑовÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/43/18/">ÐиÑов</a></li></ul></section><section><p><b>Ðоми РеÑпÑблика</b></p><ul class="cities"><li><a href="/11/489/">СÑкÑÑвкаÑ</a></li><li><a href="/11/462/">ÐоÑкÑÑа</a></li><li><a href="/11/347/">УÑинÑк</a></li><li><a href="/11/468/">УÑ
Ñа</a></li></ul></section><section><p><b>ÐоÑÑÑомÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/44/19/">ÐоÑÑÑома</a></li><li><a href="/44/1501/">ÐаÑаваево</a></li></ul></section><section><p><b>ÐÑаÑнодаÑÑкий кÑай</b></p><ul class="cities"><li><a href="/23/20/">ÐÑаÑнодаÑ</a></li><li><a href="/23/446/">Ðнапа</a></li><li><a href="/23/513/">ÐÑмавиÑ</a></li><li><a href="/23/340/">ÐелоÑеÑенÑк</a></li><li><a href="/23/505/">Ðеленджик</a></li><li><a href="/23/103/">ÐйÑк</a></li><li><a href="/23/107/">ÐовоÑоÑÑийÑк</a></li><li><a href="/23/185/">СлавÑнÑк-на-ÐÑбани</a></li><li><a href="/23/47/">СоÑи</a></li><li><a href="/23/1292/">ТемÑÑк</a></li><li><a href="/23/273/">ТиÑ
оÑеÑк</a></li><li><a href="/23/401/">ТÑапÑе</a></li></ul></section><section><p><b>ÐÑаÑноÑÑÑкий кÑай</b></p><ul class="cities"><li><a href="/24/21/">ÐÑаÑноÑÑÑк</a></li><li><a href="/24/432/">ÐÑинÑк</a></li><li><a href="/24/463/">ÐеÑоÑибиÑÑк</a></li><li><a href="/24/115/">ÐоÑилÑÑк</a></li></ul></section><section><p><b>ÐÑÑм РеÑпÑблика</b></p><ul class="cities"><li><a href="/84/535/">СеваÑÑополÑ</a></li><li><a href="/84/2242/">ÐÑмÑнÑк</a></li><li><a href="/84/2240/">ÐвпаÑоÑиÑ</a></li><li><a href="/84/2426/">ÐеÑÑÑ</a></li><li><a href="/84/632/">СимÑеÑополÑ</a></li><li><a href="/84/2284/">СовÑ
озное</a></li><li><a href="/84/2241/">ЯлÑа</a></li></ul></section><section><p><b>ÐÑÑганÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/45/486/">ÐÑÑган</a></li><li><a href="/45/2269/">ÐÑÑган-16</a></li><li><a href="/45/487/">ÐеÑниково</a></li><li><a href="/45/465/">ШадÑинÑк</a></li></ul></section><section><p><b>ÐÑÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/46/22/">ÐÑÑÑк</a></li></ul></section><section><p><b>ÐенингÑадÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/47/312/">ÐолÑ
ов</a></li><li><a href="/47/343/">ÐÑбоÑг</a></li><li><a href="/47/298/">ÐаÑÑина</a></li><li><a href="/47/255/">ÐвангоÑод</a></li><li><a href="/47/485/">ÐÑга</a></li><li><a href="/47/2282/">ÐÑÑино</a></li><li><a href="/47/449/">СоÑновÑй ÐоÑ</a></li></ul></section><section><p><b>ÐипеÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/48/23/">ÐипеÑк</a></li><li><a href="/48/499/">ÐлеÑ</a></li></ul></section><section><p><b>ÐагаданÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/49/135/">Ðагадан</a></li></ul></section><section><p><b>ÐаÑий Ðл РеÑпÑблика</b></p><ul class="cities"><li><a href="/12/483/">ÐоÑкаÑ-Ðла</a></li></ul></section><section><p><b>ÐоÑÐ´Ð¾Ð²Ð¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/13/481/">СаÑанÑк</a></li><li><a href="/13/361/">Ð Ñзаевка</a></li></ul></section><section><p><b>ÐоÑковÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/50/74/">ÐалаÑиÑ
а</a></li><li><a href="/50/1808/">ÐолÑÑие ÐÑзÑмÑ</a></li><li><a href="/50/82/">ÐÑонниÑÑ</a></li><li><a href="/50/147/">Ðидное</a></li><li><a href="/50/102/">ÐолоколамÑк</a></li><li><a href="/50/116/">ÐоÑкÑеÑенÑк</a></li><li><a href="/50/261/">ÐолиÑÑно</a></li><li><a href="/50/87/">ÐмиÑÑов</a></li><li><a href="/50/117/">Ðомодедово</a></li><li><a href="/50/111/">ÐÑбна</a></li><li><a href="/50/85/">ÐгоÑÑевÑк</a></li><li><a href="/50/84/">ÐÑковÑкий</a></li><li><a href="/50/127/">Ðлин</a></li><li><a href="/50/75/">Ðоломна</a></li><li><a href="/50/122/">ÐоÑолев</a></li><li><a href="/50/1064/">ÐоÑелÑники</a></li><li><a href="/50/2275/">ÐÑаÑково</a></li><li><a href="/50/69/">ÐÑаÑногоÑÑк</a></li><li><a href="/50/110/">ÐÑбеÑÑÑ</a></li><li><a href="/50/2271/">ÐалаÑ
овка</a></li><li><a href="/50/88/">ÐÑÑиÑи</a></li><li><a href="/50/113/">ÐдинÑово</a></li><li><a href="/50/124/">ÐÑеÑ
ово-ÐÑево</a></li><li><a href="/50/79/">ÐавловÑкий ÐоÑад</a></li><li><a href="/50/195/">ÐÑоÑвино</a></li><li><a href="/50/67/">ÐÑÑино</a></li><li><a href="/50/351/">Ð Ñбное</a></li><li><a href="/50/125/">СеÑгиев ÐоÑад</a></li><li><a href="/50/80/">СеÑпÑÑ
ов</a></li><li><a href="/50/2239/">Сколково</a></li><li><a href="/50/1897/">СÑаÑоÑеÑÑево</a></li><li><a href="/50/68/">СÑÑпино</a></li><li><a href="/50/112/">ФÑÑзино</a></li><li><a href="/50/83/">Химки</a></li><li><a href="/50/2270/">ЧеÑкизово</a></li><li><a href="/50/540/">ÐлекÑÑоизолÑÑоÑ</a></li><li><a href="/50/91/">ÐлекÑÑоÑÑалÑ</a></li></ul></section><section><p><b>ÐÑÑманÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/51/28/">ÐÑÑманÑк</a></li><li><a href="/51/396/">ÐпаÑиÑÑ</a></li></ul></section><section><p><b>ÐижегоÑодÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/52/30/">Ðижний ÐовгоÑод</a></li><li><a href="/52/514/">ÐÑзамаÑ</a></li><li><a href="/52/193/">ÐÑкÑа</a></li><li><a href="/52/460/">ÐзеÑжинÑк</a></li><li><a href="/52/184/">ÐнÑгинино</a></li><li><a href="/52/194/">Ðавлово</a></li><li><a href="/52/363/">СаÑов</a></li></ul></section><section><p><b>ÐовгоÑодÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/53/480/">Ðеликий ÐовгоÑод</a></li></ul></section><section><p><b>ÐовоÑибиÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/54/32/">ÐовоÑибиÑÑк</a></li><li><a href="/54/443/">ÐÑйбÑÑев</a></li></ul></section><section><p><b>ÐмÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/55/33/">ÐмÑк</a></li><li><a href="/55/439/">ТаÑа</a></li></ul></section><section><p><b>ÐÑенбÑÑгÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/56/35/">ÐÑенбÑÑг</a></li><li><a href="/56/410/">ÐÑзÑлÑк</a></li><li><a href="/56/256/">ÐовоÑÑоиÑк</a></li><li><a href="/56/433/">ÐÑÑк</a></li></ul></section><section><p><b>ÐÑловÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/57/34/">ÐÑел</a></li><li><a href="/57/376/">ÐивнÑ</a></li></ul></section><section><p><b>ÐензенÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/58/36/">Ðенза</a></li><li><a href="/58/2263/">Ðенза-5</a></li></ul></section><section><p><b>ÐеÑмÑкий кÑай</b></p><ul class="cities"><li><a href="/59/37/">ÐеÑмÑ</a></li><li><a href="/59/436/">ÐеÑезники</a></li><li><a href="/59/276/">ÐÑÑÑва</a></li><li><a href="/59/474/">СоликамÑк</a></li><li><a href="/59/466/">ЧайковÑкий</a></li></ul></section><section><p><b>ÐÑимоÑÑкий кÑай</b></p><ul class="cities"><li><a href="/25/5/">ÐладивоÑÑок</a></li><li><a href="/25/454/">ÐÑÑенÑев</a></li><li><a href="/25/448/">ÐолÑÑой ÐаменÑ</a></li><li><a href="/25/496/">ÐаÑ
одка</a></li><li><a href="/25/477/">УÑÑÑÑийÑк</a></li></ul></section><section><p><b>ÐÑковÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/60/39/">ÐÑков</a></li><li><a href="/60/506/">Ðеликие ÐÑки</a></li></ul></section><section><p><b>РоÑÑовÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/61/40/">РоÑÑов-на-ÐонÑ</a></li><li><a href="/61/444/">ÐолгодонÑк</a></li><li><a href="/61/207/">ÐÑково</a></li><li><a href="/61/518/">ÐеÑногÑад</a></li><li><a href="/61/139/">ÐаменÑк-ШаÑ
ÑинÑкий</a></li><li><a href="/61/246/">ÐиллеÑово</a></li><li><a href="/61/479/">ÐовоÑеÑкаÑÑк</a></li><li><a href="/61/501/">ÐеÑÑиановÑкий</a></li><li><a href="/61/473/">ТаганÑог</a></li><li><a href="/61/142/">ШаÑ
ÑÑ</a></li></ul></section><section><p><b>Ð ÑзанÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/62/41/">Ð ÑзанÑ</a></li></ul></section><section><p><b>СамаÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/63/43/">СамаÑа</a></li><li><a href="/63/475/">ÐинелÑ</a></li><li><a href="/63/452/">СÑзÑанÑ</a></li><li><a href="/63/93/">ТолÑÑÑÑи</a></li></ul></section><section><p><b>СаÑаÑовÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/64/45/">СаÑаÑов</a></li><li><a href="/64/131/">Ðалаково</a></li><li><a href="/64/132/">ÐалаÑов</a></li><li><a href="/64/183/">ÐолÑÑк</a></li><li><a href="/64/461/">ÐнгелÑÑ</a></li></ul></section><section><p><b>СаÑ
а (ЯкÑÑиÑ) РеÑпÑблика</b></p><ul class="cities"><li><a href="/14/63/">ЯкÑÑÑк</a></li><li><a href="/14/457/">ÐиÑнÑй</a></li><li><a href="/14/458/">ÐеÑÑнгÑи</a></li><li><a href="/14/324/">ÐкÑемÑÑ</a></li><li><a href="/14/1495/">ЧÑÑапÑа</a></li></ul></section><section><p><b>СаÑ
алинÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/65/62/">Южно-СаÑ
алинÑк</a></li></ul></section><section><p><b>СвеÑдловÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/66/11/">ÐкаÑеÑинбÑÑг</a></li><li><a href="/66/909/">ÐеÑÑ
нÑÑ ÐÑÑма</a></li><li><a href="/66/228/">ÐеÑÑ
нÑÑ Ð¡Ð°Ð»Ð´Ð°</a></li><li><a href="/66/229/">ÐÑаÑноÑÑÑÑинÑк</a></li><li><a href="/66/238/">ÐеÑной</a></li><li><a href="/66/89/">Ðижний Тагил</a></li><li><a href="/66/302/">ÐовоÑÑалÑÑк</a></li></ul></section><section><p><b>СевеÑÐ½Ð°Ñ ÐÑеÑÐ¸Ñ ÐланиÑ</b></p><ul class="cities"><li><a href="/15/6/">Ðладикавказ</a></li></ul></section><section><p><b>СмоленÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/67/46/">СмоленÑк</a></li><li><a href="/67/373/">ÐÑзÑма</a></li></ul></section><section><p><b>СÑавÑополÑÑкий кÑай</b></p><ul class="cities"><li><a href="/26/27/">СÑавÑополÑ</a></li><li><a href="/26/498/">ÐÑÑенÑÑки</a></li><li><a href="/26/137/">ÐиÑловодÑк</a></li><li><a href="/26/120/">ÐеÑмонÑов</a></li><li><a href="/26/402/">ÐинеÑалÑнÑе ÐодÑ</a></li><li><a href="/26/413/">ÐевинномÑÑÑк</a></li><li><a href="/26/495/">ÐÑÑигоÑÑк</a></li></ul></section><section><p><b>ТамбовÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/68/48/">Тамбов</a></li><li><a href="/68/482/">ÐиÑÑÑинÑк</a></li></ul></section><section><p><b>ТаÑаÑÑÑан РеÑпÑблика</b></p><ul class="cities"><li><a href="/16/14/">ÐазанÑ</a></li><li><a href="/16/517/">ÐлÑмеÑÑевÑк</a></li><li><a href="/16/286/">ÐÑгÑлÑма</a></li><li><a href="/16/500/">ÐлабÑга</a></li><li><a href="/16/186/">ÐениногоÑÑк</a></li><li><a href="/16/72/">ÐабеÑежнÑе ЧелнÑ</a></li><li><a href="/16/417/">ÐижнекамÑк</a></li></ul></section><section><p><b>ТвеÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/69/49/">ТвеÑÑ</a></li><li><a href="/69/2265/">ТвеÑÑ-22</a></li></ul></section><section><p><b>ТомÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/70/50/">ТомÑк</a></li><li><a href="/70/441/">СевеÑÑк</a></li></ul></section><section><p><b>ТÑлÑÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/71/51/">ТÑла</a></li><li><a href="/71/114/">ÐовомоÑковÑк</a></li></ul></section><section><p><b>ТÑва РеÑпÑблика</b></p><ul class="cities"><li><a href="/17/471/">ÐÑзÑл</a></li></ul></section><section><p><b>ТÑменÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/72/52/">ТÑменÑ</a></li><li><a href="/72/493/">ÐÑим</a></li><li><a href="/72/472/">ТоболÑÑк</a></li></ul></section><section><p><b>УдмÑÑÑÑÐºÐ°Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/18/65/">ÐжевÑк</a></li><li><a href="/18/358/">ÐоÑкинÑк</a></li><li><a href="/18/504/">Ðлазов</a></li><li><a href="/18/359/">СаÑапÑл</a></li></ul></section><section><p><b>УлÑÑновÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/73/53/">УлÑÑновÑк</a></li><li><a href="/73/453/">ÐимиÑÑовгÑад</a></li></ul></section><section><p><b>ХабаÑовÑкий кÑай</b></p><ul class="cities"><li><a href="/27/55/">ХабаÑовÑк</a></li><li><a href="/27/488/">ÐомÑомолÑÑк-на-ÐмÑÑе</a></li></ul></section><section><p><b>ХакаÑÐ¸Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/19/467/">Ðбакан</a></li><li><a href="/19/306/">СаÑногоÑÑк</a></li></ul></section><section><p><b>ХанÑÑ-ÐанÑийÑкий AO</b></p><ul class="cities"><li><a href="/81/56/">ХанÑÑ-ÐанÑийÑк</a></li><li><a href="/81/105/">ÐижневаÑÑовÑк</a></li><li><a href="/81/101/">СÑÑгÑÑ</a></li></ul></section><section><p><b>ЧелÑбинÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/74/58/">ЧелÑбинÑк</a></li><li><a href="/74/429/">ÐлаÑоÑÑÑ</a></li><li><a href="/74/484/">ÐагниÑогоÑÑк</a></li><li><a href="/74/394/">ÐиаÑÑ</a></li><li><a href="/74/313/">ÐиаÑÑкое</a></li><li><a href="/74/287/">ÐзеÑÑк</a></li><li><a href="/74/415/">СнежинÑк</a></li><li><a href="/74/234/">ТÑеÑ
гоÑнÑй</a></li><li><a href="/74/469/">ТÑоиÑк</a></li></ul></section><section><p><b>ЧеÑенÑÐºÐ°Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/20/66/">ÐÑознÑй</a></li></ul></section><section><p><b>ЧÑваÑÑÐºÐ°Ñ Ð ÐµÑпÑблика</b></p><ul class="cities"><li><a href="/21/57/">ЧебокÑаÑÑ</a></li><li><a href="/21/423/">ÐлаÑÑÑÑ</a></li></ul></section><section><p><b>ЧÑкоÑÑкий AO</b></p><ul class="cities"><li><a href="/82/236/">ÐнадÑÑÑ</a></li></ul></section><section><p><b>ЯÑоÑлавÑÐºÐ°Ñ Ð¾Ð±Ð»Ð°ÑÑÑ</b></p><ul class="cities"><li><a href="/76/64/">ЯÑоÑлавлÑ</a></li><li><a href="/76/476/">Ð ÑбинÑк</a></li><li><a href="/76/328/">ТÑÑаев</a></li></ul></section>7'''8#test = np.array([['a', 'a', 'a', 'a', 'a', 'a', 'a']])9#itemprop="url"><a href="http://noungi.ru" 10#itemprop="email">ngi_04@mail.ru</p>11#itemprop="telephone"><a href="tel:+74965738839">+7 (496) 573-88-39 </a></div>12#<meta name="Keywords" content="Ð ÐСУ в г. Ðлин, РоÑÑийÑкий гоÑÑдаÑÑÑвеннÑй ÑоÑиалÑнÑй ÑнивеÑÑиÑÐµÑ â Ñилиал в г. Ðлин, обÑÐ°Ñ Ð¸Ð½ÑоÑмаÑиÑ,13url = 'https://vuz.edunetwork.ru'14def get_info(text):15 info = ['-']*716 end = '<p class="bold"'17 #end2 = 18 title = '<meta name="Keywords" content='19 start_info ='<h2>ÐбÑÐ°Ñ Ð¸Ð½ÑоÑмаÑиÑ</h2>'20 fl = 021 find_full_name = '"legalName">(.*?)</p>'22 country = 'addressCountry'23 for i in range(len(text)):24 if title in text[i]:25 a = re.findall(r'<meta name="Keywords" content="(.*?), обÑÐ°Ñ Ð¸Ð½ÑоÑмаÑиÑ', text[i])26 a = a[0].split(', ')27 info[0] = a[1].strip()28 info[2] = a[0].strip()29 #if start_info in text[i]:30 try:31 if 'legalName' in text[i]:32 fl = 133 a = re.findall(r'"legalName">(.*?)</p>', text[i])34 info[1] = a[0].strip()35 36 if 'addressCountry' in text[i] and fl == 1:37 info[3] = text[i+1].strip()38 39 if 'itemprop="url"' in text[i] and fl == 1:40 a = re.findall(r'itemprop="url"><a href="(.*?)" target="_blank">', text[i])41 info[4] = a[0].strip()42 43 if 'itemprop="email"' in text[i] and fl == 1:44 a = re.findall(r'itemprop="email">(.*?)</p>', text[i])45 info[5] = a[0].strip()46 if 'itemprop="telephone"' in text[i] and fl == 1:47 a = re.findall(r'itemprop="telephone"><a href="tel:(.*?)">', text[i])48 info[6] = a[0].strip()49 except IndexError:50 continue51 if end in text[i]:52 break53 print(info[0])54 return info55def parse_universe(text):56 unit = 'unit-name'57 end = '<span id="helper-title">РвÑзÑ, оÑмеÑеннÑе' 58 links = []59 for i in range(len(text)):60 if end in text[i]:61 break62 if unit in text[i]:63 link = re.findall(r'<a href="(.*?)"', text[i+1])64 links.append(link)65 return links66def get_text_url(k , url_text):67 test = np.array([['a', 'a', 'a', 'a', 'a', 'a', 'a']])68 page = '/?page='69 for i in range(0, k):70 time.sleep(np.random.randint(2,8))71 full_url = url+url_text+page+str(i)72 res = ses.get(full_url)73 #time.sleep(np.random.randint(2,8))74 text = res.text.split('\n')75 links = parse_universe(text)76 for link in links:77 time.sleep(np.random.randint(2,8))78 res = ses.get(url+link[0])79 text = res.text.split('\n')80 info = np.array([get_info(text)])81 test = np.append(test, info, axis=0)82 return test[1:test.shape[0]]83#df = pd.DataFrame(columns = ('Ðазвание ÐУÐа', 'Ðолное название ÐУÐÐ', 'СокÑаÑенное название ÐУÐÐ', 'ÐдÑеÑ', 'СайÑ', 'ÐоÑÑа', 'ТелеÑон'))84if __name__ == '__main__':85 test = np.array([['a', 'a', 'a', 'a', 'a', 'a', 'a']])86 #url = 'https://vuz.edunetwork.ru'87 moscow_url = '/77/'88 spb_url = '/78/'89 page = '/?page='90 unit = 'unit-name'91 end = '<span id="helper-title">РвÑзÑ, оÑмеÑеннÑе'92 all_links = re.findall(r'<a href="(.*?)/"', cities)93 with requests.Session() as ses:94 #ses.headers = {'HH-User-Agent': 'Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Firefox/91.0'}95 ses.headers = {'HH-User-Agent': "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 YaBrowser/22.1.0.2510 Yowser/2.5 Safari/537.36"}96 97 test = np.append(test, get_text_url(5, moscow_url), axis = 0)98 test = test[1:test.shape[0]]99 test = np.append(test, get_text_url(3, spb_url), axis= 0)100 for link in all_links:101 test = np.append(test, get_text_url(1, link), axis=0)102 df = pd.DataFrame(test, columns = ['Ðазвание', 'Ðолное название', 'СокÑаÑенное название', 'ÐдÑеÑ', 'СайÑ', 'ÐоÑÑа', 'ТелеÑон'])103 df.to_csv('ÐÑÑ Ð¸Ð½ÑоÑмаÑÐ¸Ñ Ð¿Ð¾ ÑнивеÑÑиÑеÑам РоÑÑии.csv', index = False, encoding = 'utf-8')104 #print(test)105 #res = ses.get(url)106 #text = res.text.split('\n')...
test_sanitize.py
Source:test_sanitize.py
1# adapted from http://www.iamcal.com/publish/articles/php/processing_html_part_2/2# and from http://feedparser.org/tests/wellformed/sanitize/3# by Aaron Swartz, 2006, public domain4import unittest, new5from planet import sanitize6class SanitizeTest(unittest.TestCase): pass7# each call to HTML adds a test case to SanitizeTest8testcases = 09def HTML(a, b):10 global testcases11 testcases += 112 func = lambda self: self.assertEqual(sanitize.HTML(a), b)13 method = new.instancemethod(func, None, SanitizeTest)14 setattr(SanitizeTest, "test_%d" % testcases, method)15## basics16HTML("","")17HTML("hello","hello")18## balancing tags19HTML("<b>hello","<b>hello</b>")20HTML("hello<b>","hello<b></b>")21HTML("hello</b>","hello")22HTML("hello<b/>","hello<b></b>")23HTML("<b><b><b>hello","<b><b><b>hello</b></b></b>")24HTML("</b><b>","<b></b>")25## trailing slashes26HTML('<img>','<img />')27HTML('<img/>','<img />')28HTML('<b/></b>','<b></b>')29## balancing angle brakets30HTML('<img src="foo"','')31HTML('b>','b>')32HTML('<img src="foo"/','')33HTML('>','>')34HTML('foo<b','foo')35HTML('b>foo','b>foo')36HTML('><b','>')37HTML('b><','b>')38HTML('><b>','><b></b>')39## attributes40HTML('<img src=foo>','<img src="foo" />')41HTML('<img asrc=foo>','<img />')42HTML('<img src=test test>','<img src="test" />')43## dangerous tags (a small sample)44sHTML = lambda x: HTML(x, 'safe <b>description</b>')45sHTML('safe<applet code="foo.class" codebase="http://example.com/"></applet> <b>description</b>')46sHTML('<notinventedyet>safe</notinventedyet> <b>description</b>')47sHTML('<blink>safe</blink> <b>description</b>')48sHTML('safe<embed src="http://example.com/"> <b>description</b>')49sHTML('safe<frameset rows="*"><frame src="http://example.com/"></frameset> <b>description</b>')50sHTML('safe<iframe src="http://example.com/"> <b>description</b></iframe>')51sHTML('safe<link rel="stylesheet" type="text/css" href="http://example.com/evil.css"> <b>description</b>')52sHTML('safe<meta http-equiv="Refresh" content="0; URL=http://example.com/"> <b>description</b>')53sHTML('safe<object classid="clsid:C932BA85-4374-101B-A56C-00AA003668DC"> <b>description</b>')54sHTML('safe<script type="text/javascript">location.href=\'http:/\'+\'/example.com/\';</script> <b>description</b>')55for x in ['onabort', 'onblur', 'onchange', 'onclick', 'ondblclick', 'onerror', 'onfocus', 'onkeydown', 'onkeypress', 'onkeyup', 'onload', 'onmousedown', 'onmouseout', 'onmouseover', 'onmouseup', 'onreset', 'resize', 'onsubmit', 'onunload']:56 HTML('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" %s="location.href=\'http://www.ragingplatypus.com/\';" />' % x,57 '<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />')58HTML('<a href="http://www.ragingplatypus.com/" style="display:block; position:absolute; left:0; top:0; width:100%; height:100%; z-index:1; background-color:black; background-image:url(http://www.ragingplatypus.com/i/cam-full.jpg); background-x:center; background-y:center; background-repeat:repeat;">never trust your upstream platypus</a>', '<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>')59## ignorables60HTML('foo<style>bar', 'foo')61HTML('foo<style>bar</style>', 'foo')62## non-allowed tags63HTML('<script>','')64HTML('<script','')65HTML('<script/>','')66HTML('</script>','')67HTML('<script woo=yay>','')68HTML('<script woo="yay">','')69HTML('<script woo="yay>','')70HTML('<script woo="yay<b>','')71HTML('<script<script>>','')72HTML('<<script>script<script>>','')73HTML('<<script><script>>','')74HTML('<<script>script>>','')75HTML('<<script<script>>','')76## bad protocols77HTML('<a href="http://foo">bar</a>', '<a href="http://foo">bar</a>')78HTML('<a href="ftp://foo">bar</a>', '<a href="ftp://foo">bar</a>')79HTML('<a href="mailto:foo">bar</a>', '<a href="mailto:foo">bar</a>')80# not yet supported:81#HTML('<a href="javascript:foo">bar</a>', '<a href="#foo">bar</a>')82#HTML('<a href="java script:foo">bar</a>', '<a href="#foo">bar</a>')83#HTML('<a href="java\tscript:foo">bar</a>', '<a href="#foo">bar</a>')84#HTML('<a href="java\nscript:foo">bar</a>', '<a href="#foo">bar</a>')85#HTML('<a href="java'+chr(1)+'script:foo">bar</a>', '<a href="#foo">bar</a>')86#HTML('<a href="jscript:foo">bar</a>', '<a href="#foo">bar</a>')87#HTML('<a href="vbscript:foo">bar</a>', '<a href="#foo">bar</a>')88#HTML('<a href="view-source:foo">bar</a>', '<a href="#foo">bar</a>')89## auto closers90HTML('<img src="a">', '<img src="a" />')91HTML('<img src="a">foo</img>', '<img src="a" />foo')92HTML('</img>', '')93## crazy: http://alpha-geek.com/example/crazy_html2.html94HTML('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\r\n\r\n<html xmlns="http://www.w3.org/1999/xhtml">\r\n<head>\r\n<title>Crazy HTML -- Can Your Regex Parse This?</title>\r\n</head>\r\n<body notRealAttribute="value"onload="executeMe();"foo="bar"\r\n\r\n>\r\n<!-- <script> -->\r\n\r\n<!-- \r\n\t<script> \r\n-->\r\n\r\n</script>\r\n\r\n\r\n<script\r\n\r\n\r\n>\r\n\r\nfunction executeMe()\r\n{\r\n\r\n\r\n\r\n\r\n/* <script> \r\nfunction am_i_javascript()\r\n{\r\n\tvar str = "Some innocuously commented out stuff";\r\n}\r\n< /script>\r\n*/\r\n\r\n\t\r\n\t\r\n\t\r\n\t\r\n\t\r\n\t\r\n\t\r\n\t\r\n\talert("Executed");\r\n}\r\n\r\n </script\r\n\r\n\r\n\r\n>\r\n<h1>Did The Javascript Execute?</h1>\r\n<div notRealAttribute="value\r\n"onmouseover="\r\nexecuteMe();\r\n"foo="bar">\r\nI will execute here, too, if you mouse over me\r\n</div>\r\nThis is to keep you guys honest...<br />\r\nI like ontonology. I like to script ontology. Though, script>style>this.\r\n</body>\r\n</html>', 'Crazy HTML -- Can Your Regex Parse This?\n\n\n<!-- <script> -->\n\n<!-- \n\t<script> \n-->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>\nThis is to keep you guys honest...<br />\nI like ontonology. I like to script ontology. Though, script>style>this.')95# valid entity references96HTML(" "," ");97HTML(" "," ");98HTML(" "," ");99HTML(" "," ");100# unescaped ampersands101HTML("AT&T","AT&T");102HTML("http://example.org?a=1&b=2","http://example.org?a=1&b=2");103# quote characters104HTML('<a title=""">quote</a>','<a title=""">quote</a>')...
pyquerys.py
Source:pyquerys.py
1# coding=utf-82from pyquery import PyQuery as pq3# å符串åå§å4html = '''5<div id="container">6 <ul class="list">7 <li class="item-0">first item</li>8 <li class="item-1"><a href="link2.html">second item</a></li>9 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>10 <li class="item-1 active"><a href="link4.html">fourth item</a></li>11 <li class="item-0"><a href="link5.html">fifth item</a></li>12 </ul>13 </div>14'''15doc = pq(html)16print(doc('li'))17# urlåå§å18doc = pq('http://www.baidu.com')19print(doc('html'))20# æ件åå§å21with open('demo.html', 'wb') as file:22 file.write(html.encode())23 file.close()24doc = pq(filename='demo.html')25print(doc('li'))26# åºæ¬csséæ©å¨27doc = pq(html)28item = doc('#container .list')29print(item)30print(type(item))31print(item.find('li'))32print(item.children('.active'))33print(item.find('.active'))34item = doc('.item-0')35print(item.parent())36print(item.parents())37print(item.parents('.list'))38# å
å¼å
ç´ 39html = '''40<div class="wrap">41 <div id="container">42 <ul class="list">43 <li class="item-0">first item</li>44 <li class="item-1"><a href="link2.html">second item</a></li>45 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>46 <li class="item-1 active"><a href="link4.html">fourth item</a></li>47 <li class="item-0"><a href="link5.html">fifth item</a></li>48 </ul>49 </div>50 </div>51'''52doc = pq(html)53li = doc('.list .item-0.active')54print(li.siblings())55print(li.siblings('.active'))56# éå57html = '''58<div class="wrap">59 <div id="container">60 <ul class="list">61 <li class="item-0">first item</li>62 <li class="item-1"><a href="link2.html">second item</a></li>63 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>64 <li class="item-1 active"><a href="link4.html">fourth item</a></li>65 <li class="item-0"><a href="link5.html">fifth item</a></li>66 </ul>67 </div>68 </div>69'''70doc = pq(html)71li = doc('.item0.active')72print(li)73lis=doc('li').items()74for li in lis:75 print(li)76# è·åå±æ§77html = '''78<div class="wrap">79 <div id="container">80 <ul class="list">81 <li class="item-0">first item</li>82 <li class="item-1"><a href="link2.html">second item</a></li>83 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>84 <li class="item-1 active"><a href="link4.html">fourth item</a></li>85 <li class="item-0"><a href="link5.html">fifth item</a></li>86 </ul>87 </div>88 </div>89'''90doc = pq(html)91a = doc('.item-0.active a')92print(a)93print(a.attr('href'))94print(a.attr.href)95# è·åææ¬96html = '''97<div class="wrap">98 <div id="container">99 <ul class="list">100 <li class="item-0">first item</li>101 <li class="item-1"><a href="link2.html">second item</a></li>102 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>103 <li class="item-1 active"><a href="link4.html">fourth item</a></li>104 <li class="item-0"><a href="link5.html">fifth item</a></li>105 </ul>106 </div>107 </div>108'''109doc = pq(html)110a = doc('.item-0.active a')111print(a)112print(a.text())113# è·åhtml114html = '''115<div class="wrap">116 <div id="container">117 <ul class="list">118 <li class="item-0">first item</li>119 <li class="item-1"><a href="link2.html">second item</a></li>120 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>121 <li class="item-1 active"><a href="link4.html">fourth item</a></li>122 <li class="item-0"><a href="link5.html">fifth item</a></li>123 </ul>124 </div>125 </div>126'''127doc = pq(html)128li = doc('.item-0.active')129print(li)130print(li.html())131# DOMæä½132html = '''133<div class="wrap">134 <div id="container">135 <ul class="list">136 <li class="item-0">first item</li>137 <li class="item-1"><a href="link2.html">second item</a></li>138 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>139 <li class="item-1 active"><a href="link4.html">fourth item</a></li>140 <li class="item-0"><a href="link5.html">fifth item</a></li>141 </ul>142 <p>This is a paragraph.</p>143 </div>144 </div>145'''146doc = pq(html)147li = doc('.item-0.active')148print(li)149li.removeClass('active')150print(li)151li.addClass('active')152print(li)153doc = pq(html)154li = doc('.item-0.active')155print(li)156li.attr('name', 'link')157print(li)158li.css('font-size', '14px')159print(li)160wrap = doc('.wrap')161print(wrap.text())162wrap.find('p').remove()163print(wrap.text())164# 伪类éæ©å¨165html = '''166<div class="wrap">167 <div id="container">168 <ul class="list">169 <li class="item-0">first item</li>170 <li class="item-1"><a href="link2.html">second item</a></li>171 <li class="item-0 active"><a href="link3.html"><span class="bold">third item</span></a></li>172 <li class="item-1 active"><a href="link4.html">fourth item</a></li>173 <li class="item-0"><a href="link5.html">fifth item</a></li>174 </ul>175 </div>176 </div>177'''178doc = pq(html)179li = doc('li:first-child')180print(li)181li = doc('li:last-child')182print(li)183li = doc('li:nth-child(2)')184print(li)185li = doc('li:gt(2)')186print(li)187li = doc('li:nth-child(2n)')188print(li)189li = doc('li:contains(second)')...
scrap_dir.py
Source:scrap_dir.py
1#!/usr/bin/env python32import sys3import json4import requests5import bs46def guess_field(field, contact):7 link = field.find('a')8 href = link.get('href') if link is not None else None9 if href is not None and contact.get('href') == href:10 return {'surname': link.text}11 return ()12def name_field(field, contact):13 link = field.find('a')14 return {'name': link.text, 'href': link.get('href')}15def opt_field(key):16 def extract(field, contact):17 link = field.find('a')18 return {key: link.text} if link is not None else ()19 return extract20FIELDS = {21 '': guess_field,22 'name': name_field,23 'telephone': opt_field('tel'),24 'email': opt_field('email'),25}26ROOT = 'https://www.tec.ac.cr'27session = requests.Session()28def http_get(uri):29 global session30 response = session.get(f'{ROOT}/{uri}')31 assert response.status_code == 20032 return bs4.BeautifulSoup(response.text, 'lxml')33page_no = 034staff = []35while True:36 table = http_get(f'directorio-contactos-0?page={page_no}').find('table')37 if table is None:38 break39 print('\rEnumerating page', 1 + page_no,40 end='...', flush=True, file=sys.stderr)41 for element in table.find('tbody').find_all('tr'):42 contact = {}43 for field in element.find_all('td'):44 klass = field.get('class') or ('',)45 if len(klass) == 1:46 contact.update((FIELDS.get(klass[0]) or (47 lambda *_: ()))(field, contact))48 staff.append(contact)49 page_no += 150total = len(staff)51print('\nFound', total, 'staff members', file=sys.stderr)52depts = []53dept_indices = {}54def dept_idx(roles):55 global depts, dept_indices56 link = roles.find('h3').find('a')57 href = link.get('href')58 idx = dept_indices.get(href)59 if idx is None:60 idx = len(depts)61 depts.append({'href': href, 'name': link.text})62 dept_indices[href] = idx63 print('\nNew dept [', idx, '] ', href, ': ',64 link.text, sep='', file=sys.stderr)65 return idx66staff_types = []67staff_type_indices = {}68def row_types(row, klass):69 global staff_type_indices70 div = row.find('div', {'class': klass})71 if div is None:72 return []73 types = []74 for tag in div.text.split(', '):75 idx = staff_type_indices.get(tag)76 if idx is None:77 idx = len(staff_types)78 staff_types.append(tag)79 staff_type_indices[tag] = idx80 print('\nNew staff type [', idx, '] ',81 tag, sep='', file=sys.stderr)82 types.append(idx)83 return types84locations = []85def row_location(row):86 global locations87 div = row.find('div', {'class': 'campus'})88 if div is None:89 return None90 link = div.find('a')91 href = link.get('href').replace(ROOT, '')92 for idx, location in enumerate(locations):93 if location['href'] == href:94 break95 else:96 idx = len(locations)97 locations.append({'href': href, 'name': link.text})98 print('\nNew location [', idx, '] ', href,99 ': ', link.text, sep='', file=sys.stderr)100 return idx101for i, contact in enumerate(staff):102 print('\rQuerying member ', i + 1, '/', total, '...',103 sep='', end='', flush=True, file=sys.stderr)104 href = contact.get('href')105 if href is None:106 print('\nError: no href in contact:', contact, file=sys.stderr)107 continue108 soup = http_get(href)109 pane = soup.find(110 'div', {'class': 'pane-staff-relations-per-contact-panel-pane-1'})111 if pane is None:112 print('\nError: no info pane in contact href:', href, file=sys.stderr)113 continue114 roles = []115 for row in pane.find_all('div', {'class': 'views-row'}):116 role = {'dept': dept_idx(row)}117 types = row_types(row, 'type')118 if types:119 role['types'] = types120 functions = row_types(row, 'rol')121 if functions:122 role['functions'] = functions123 location = row_location(row)124 if location:125 role['location'] = location126 roles.append(role)127 contact['roles'] = roles128out = {129 'staff': staff,130 'depts': depts,131 'staff_types': staff_types,132 'locations': locations,133}...
managedb.py
Source:managedb.py
1import sqlite32import data.scripts.contract as contract3import datetime4import os56conn = sqlite3.connect(str(os.getcwd()) + '\\data\\scripts\\options.db')7cursor = conn.cursor()8910# cursor.execute("""CREATE TABLE options(11# symbol text,12# strike real,13# indicator text,14# ogPrice real,15# price real,16# expDate text,17# href text,18# percentage real,19# alert integer)""")202122def insertOption(option):23 with conn:24 print("Inserting option: " + str(option.symbol))25 cursor.execute(26 "INSERT INTO options VALUES (:symbol, :strike, :indicator, :ogPrice, :price, :expDate, :href, :percentage, :alert)",27 {'symbol': option.symbol, 'strike': option.strike, 'indicator': option.indicator,28 'ogPrice': option.ogPrice, 'price': option.price, 'expDate': option.expDate, 'href': option.href,29 'percentage': option.percentage, 'alert': option.alert})303132def deleteOption(href):33 with conn:34 cursor.execute("DELETE from options WHERE href = :href",35 {'href': href})363738def deleteDuplicates():39 with conn:40 cursor.execute("CREATE TABLE tempTable as SELECT DISTINCT * FROM options")41 cursor.execute("DELETE FROM options")42 cursor.execute("INSERT INTO options SELECT * FROM tempTable")43 cursor.execute("DROP TABLE tempTable")444546def searchOptionByHref(href):47 with conn:48 cursor.execute("SELECT * FROM options WHERE href=:href", {'href': href})49 return cursor.fetchall()505152def printAllRecords():53 with conn:54 cursor.execute("SELECT * FROM options")55 print("=======================")56 print(cursor.fetchall())57 print("\n\n\n")585960def getLength():61 with conn:62 cursor.execute("SELECT * FROM options")63 length = len(cursor.fetchall())64 return length656667def updatePrice(href, price):68 with conn:69 cursor.execute("""UPDATE options SET price = :price WHERE href = :href""",70 {'href': href, 'price': float(price)})717273def updatePercentage(href, percentage):74 with conn:75 cursor.execute("""UPDATE options SET percentage = :percentage WHERE href = :href""",76 {'href': href, 'percentage': float(percentage)})777879def updateAlert(href):80 with conn:81 cursor.execute("""UPDATE options SET alert = :alert WHERE href = :href""",82 {'href': href, 'alert': 1})838485def findAllUpdates():86 with conn:87 updates = dict()88 cursor.execute("SELECT * FROM options")89 for result in cursor.fetchall():90 price = result[4]91 parsedDate = result[5].split('-')92 currentPrice = contract.getLastPrice(result[0], parsedDate, result[1], result[2])93 expireDate = datetime.date(int(parsedDate[0]), int(parsedDate[1]), int(parsedDate[2]))94 expireDate = expireDate - datetime.date.today()95 if expireDate.days <= 0:96 print("Deleted option: " + result[0] + " because it expired")97 deleteOption(result[6])98 if float(price) != float(currentPrice):99 percentage = contract.calculatePercentage(currentPrice, result[3])100 updates[result[6]] = [currentPrice, percentage, result[8]]101 return updates102103#104# toUpdate = findAllUpdates()105# for i in toUpdate:106# updatePrice(i, toUpdate[i])107#108# cursor.execute("SELECT * FROM options")109# print(cursor.fetchall())
...
links.py
Source:links.py
1""" Utility for related items2"""3from urllib2 import urlparse4from bs4 import BeautifulSoup5from zope.interface import implements6from eea.alchemy.interfaces import IDiscoverLinks7class DiscoverLinks(object):8 """ Discover internal links9 """10 implements(IDiscoverLinks)11 def __call__(self, text="", match=""):12 match = match.replace('https://', 'http://')13 soup = BeautifulSoup(text, 'lxml')14 items = set()15 for link in soup.find_all('a'):16 href = link.get('href')17 if href is None:18 continue19 href = href.replace('https://', 'http://')20 ourl = urlparse.urlparse(href)21 ourl = ourl._replace(fragment='', query='', params='')22 href = ourl.geturl()23 if u'resolveuid' in href:24 items.add(href)25 elif href.startswith('../'):26 items.add(href)27 elif match and href.startswith(match):28 found = href[len(match):]29 found = found.strip('/')30 items.add(found)31 elif href.startswith('/'):32 href = href.strip('/')33 items.add(href)34 for link in items:35 yield {36 'count': 1,37 'type': 'Link',38 'text': link,39 'relevance': '100.0'...
iframes.py
Source:iframes.py
1""" Utility for related items2"""3from urllib2 import urlparse4from bs4 import BeautifulSoup5from zope.interface import implements6from eea.alchemy.interfaces import IDiscoverIframes7class DiscoverIframes(object):8 """ Discover internal links from embeded iframes9 """10 implements(IDiscoverIframes)11 def __call__(self, text="", match=""):12 match = match.replace('https://', 'http://')13 soup = BeautifulSoup(text, 'lxml')14 items = set()15 for link in soup.find_all('iframe'):16 href = link.get('src')17 href = href.replace('https://', 'http://')18 ourl = urlparse.urlparse(href)19 ourl = ourl._replace(fragment='', query='', params='')20 href = ourl.geturl()21 if u'resolveuid' in href:22 items.add(href)23 elif href.startswith('../'):24 items.add(href)25 elif match and href.startswith(match):26 found = href[len(match):]27 found = found.strip('/')28 items.add(found)29 elif href.startswith('/'):30 href = href.strip('/')31 items.add(href)32 for link in items:33 yield {34 'count': 1,35 'type': 'Link',36 'text': link,37 'relevance': '100.0'...
Using AI Code Generation
1var wpt = require('webpagetest');2var wpt = new WebPageTest('www.webpagetest.org');3 if (err) return console.log(err);4 console.log(data);5 wpt.getTestResults(data.data.testId, function(err, data) {6 if (err) return console.log(err);7 console.log(data);8 });9});10var wpt = require('webpagetest');11var wpt = new WebPageTest('www.webpagetest.org');12 if (err) return console.log(err);13 console.log(data);14 wpt.getTestResults(data.data.testId, function(err, data) {15 if (err) return console.log(err);16 console.log(data);17 });18});19var wpt = require('webpagetest');20var wpt = new WebPageTest('www.webpagetest.org');21 if (err) return console.log(err);22 console.log(data);23 wpt.getTestResults(data.data.testId, function(err, data) {24 if (err) return console.log(err);25 console.log(data);26 });27});28var wpt = require('webpagetest');29var wpt = new WebPageTest('www.webpagetest.org');30 if (err) return console.log(err);31 console.log(data);32 wpt.getTestResults(data.data.testId, function(err, data) {33 if (err) return console.log(err);34 console.log(data);35 });36});37var wpt = require('webpagetest');38var wpt = new WebPageTest('www.webpagetest.org');39 if (err) return console.log(err);40 console.log(data);
Using AI Code Generation
1var wpt = require('webpagetest');2var wpt = new WebPageTest('www.webpagetest.org');3wpt.runTest('www.google.com', function(err, data) {4 if (err) return console.error(err);5 console.log('Test status:', data.statusText);6 wpt.getTestStatus(data.data.testId, function(err, data) {7 if (err) return console.error(err);8 console.log('Test status:', data.statusText);9 console.log('Test results:', data.data.runs[1].firstView);10 });11});
Using AI Code Generation
1var wpt = require('webpagetest');2var wpt = new WebPageTest('www.webpagetest.org');3wpt.runTest(url, function(err, data) {4 if (err) return console.error(err);5 console.log(data);6 wpt.getTestResults(data.testId, function(err, data) {7 if (err) return console.error(err);8 console.log(data);9 });10});11var wpt = require('webpagetest');12var wpt = new WebPageTest('www.webpagetest.org');13wpt.runTest(url, function(err, data) {14 if (err) return console.error(err);15 console.log(data);16 wpt.getTestResults(data.data.testId, function(err, data) {17 if (err) return console.error(err);18 console.log(data);19 });20});21var wpt = require('webpagetest');22var wpt = new WebPageTest('www.webpagetest.org');23wpt.runTest(url, function(err, data) {24 if (err) return console.error(err);25 console.log(data);26 wpt.getTestResults(data.data.testId, function(err, data) {27 if (err) return console.error(err);28 console.log(data);29 });30});31var wpt = require('webpagetest');32var wpt = new WebPageTest('www.webpagetest.org');33wpt.runTest(url, function(err, data) {34 if (err) return console.error(err);35 console.log(data);36 wpt.getTestResults(data.data.testId, function(err, data) {37 if (err) return console.error(err);38 console.log(data);39 });40});41var wpt = require('webpagetest');42var wpt = new WebPageTest('www.webpagetest.org');43wpt.runTest(url, function(err, data) {44 if (err) return console.error(err);
Using AI Code Generation
1var wpt = require('webpagetest');2var wpt = new WebPageTest('www.webpagetest.org');3wpt.runTest(url, function(err, data) {4 if (err) return console.error(err);5 console.log('Test status: ' + data.statusText);6 console.log('Test results: ' + data.data.runs[1].firstView.results);7});8var wpt = require('webpagetest');9var wpt = new WebPageTest('www.webpagetest.org');10wpt.runTest(url, function(err, data) {11 if (err) return console.error(err);12 console.log('Test status: ' + data.statusText);13 console.log('Test results: ' + data.data.runs[1].firstView.results);14});15var wpt = require('webpagetest');16var wpt = new WebPageTest('www.webpagetest.org');17wpt.runTest(url, function(err, data) {18 if (err) return console.error(err);19 console.log('Test status: ' + data.statusText);20 console.log('Test results: ' + data.data.runs[1].firstView.results);21});22var wpt = require('webpagetest');23var wpt = new WebPageTest('www.webpagetest.org');24wpt.runTest(url, function(err, data) {25 if (err) return console.error(err);26 console.log('Test status: ' + data.statusText);27 console.log('Test results: ' + data.data.runs[1].firstView.results);28});29var wpt = require('webpagetest');30var wpt = new WebPageTest('www.webpagetest.org');31wpt.runTest(url, function(err, data) {32 if (err) return console.error(err);33 console.log('Test status: ' + data.statusText);
Using AI Code Generation
1var wpt = require('webpagetest');2var wpt = new WebPageTest('www.webpagetest.org');3var testOptions = {4};5wpt.runTest(testUrl, testOptions, function(err, data) {6 if (err) return console.error(err);7 console.log(data.data.runs[1].firstView.videoFrames);8});9console.log(data.data.runs[2].firstView.videoFrames);10console.log(data.data.runs[3].firstView.videoFrames);11console.log(data.data.runs[4].firstView.videoFrames);12console.log(data.data.runs[5].firstView.videoFrames);13console.log(data.data.runs[6].firstView.videoFrames);14console.log(data.data.runs[7].firstView.videoFrames);15console.log(data.data.runs[8].firstView.videoFrames);16console.log(data.data.runs[9].firstView.videoFrames);17console.log(data.data.runs[10].firstView.videoFrames);18console.log(data.data.runs[11].firstView.videoFrames);19console.log(data.data.runs[12].firstView.videoFrames);20console.log(data.data.runs[13].firstView.videoFrames);
Using AI Code Generation
1var wpt = require('webpagetest');2var client = wpt('www.webpagetest.org');3var options = {4};5client.runTest(url, options, function(err, data) {6 if (err) return console.error(err);7 console.log('Test submitted to WebPagetest for %s', url);8 console.log('Test ID: %s', data.data.testId);9 console.log('Test status: %s', data.data.statusText);10 console.log('Test results will be available at %s', data.data.summaryCSV);11 console.log('Test results will be available at %s', data.data.summaryCSV);12 console.log('Test results will be available at %s', data.data.userUrl);13 console.log('Test results will be available at %s', data.data.jsonUrl);14 console.log('Test results will be available at %s', data.data.xmlUrl);15 console.log('Test results will be available at %s', data.data.harUrl);16 console.log('Test results will be available at %s', data.data.screenshotUrl);17 console.log('Test results will be available at %s', data.data.videoUrl);18 console.log('Test results will be available at %s', data.data.waterfallUrl);19 console.log('Test results will be available at %s', data.data.checklistUrl);20 console.log('Test results will be available at %s', data.data.reportUrl);21 console.log('Test results will be available at %s', data.data.optimizationChecklistUrl);22 console.log('Test results will be available at %s', data.data.optimizationReportUrl);23 console.log('Test results will be available at %s', data.data.pagespeedUrl);24 console.log('Test results will be available at %s', data.data.pagespeedFileUrl);25 console.log('Test results will be available at %s', data.data.videoFramesUrl);26 console.log('Test results will be available at %s', data.data.videoFramesFileUrl);27 console.log('Test results will be available at %s', data.data.videoCompareUrl);28 console.log('Test results will be available at %s', data.data.videoCompareFileUrl);29 console.log('Test results will
Using AI Code Generation
1var wpt = require('webpagetest');2var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a4e4a7a8a9a4');3 console.log(data.data.runs[1].firstView.href);4});5var wpt = require('webpagetest');6var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a4e4a7a8a9a4');7test.getTestResults('140511_2Q_1Y', function(err, data) {8 console.log(data);9});10var wpt = require('webpagetest');11var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a4e4a7a8a9a4');12test.getLocations(function(err, data) {13 console.log(data);14});15var wpt = require('webpagetest');16var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a4e4a7a8a9a4');17test.getTesters(function(err, data) {18 console.log(data);19});20var wpt = require('webpagetest');21var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a4e4a7a8a9a4');22test.getTesters(function(err, data) {23 console.log(data);24});25var wpt = require('webpagetest');26var test = new wpt('www.webpagetest.org', 'A.4e4a7a8a9a4e4a7a8a9a
Using AI Code Generation
1var wpt = require('webpagetest');2var options = {3};4var wpt = new WebPageTest('www.webpagetest.org', 'A.9d7f3a3d1b7a3c6f1e0d8a8e7a7a0f6f');5wpt.runTest(testURL, function(err, data) {6 if (err) return console.log(err);7 console.log('Test submitted to WebPageTest');8 console.log('Navigate to ' + data.data.userUrl + ' to see the test results');9});10var WebPageTest = require('webpagetest');11var wpt = new WebPageTest('www.webpagetest.org', 'A.9d7f3a3d1b7a3c6f1e0d8a8e7a7a0f6f');12wpt.runTest(testURL, function(err, data) {13 if (err) return console.log(err);14 console.log('Test submitted to WebPageTest');15 console.log('Navigate to ' + data.data.userUrl + ' to see the test results');16});17var WebPageTest = require('webpagetest');18var wpt = new WebPageTest('www.webpagetest.org', 'A.9d7f3a3d1b7a3c6f1e0d8a8e7a7a0f6f');19wpt.runTest(testURL, function(err, data) {20 if (err) return console.log(err);21 console.log('Test submitted to WebPageTest');22 console.log('Navigate to ' + data.data.userUrl + ' to see the test results');23});24var WebPageTest = require('webpagetest');
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!