function CaSearchInterface(map) { this.map = map; // map interface object this.locationTypeNames = {"aeroway_aerodrome":{"cz":"leti\u0161t\u011b","en":"aerodrome","de":"Flughafen","fr":"a\u00e9rodrome"},"bus_bus_station":{"cz":"autobusov\u00e1 zast\u00e1vka","en":"bus stop","de":"Bushaltestelle","fr":"arr\u00eat de bus"},"bus_bus_stop":{"cz":"autobusov\u00e1 zast\u00e1vka","en":"bus stop","de":"Bushaltestelle","fr":"arr\u00eat de bus"},"highway_10":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_abandoned":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_access":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_alley":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_bridleway":{"cz":"stezka pro kon\u011b","en":"bridleway","de":"Reitweg","fr":"sentier \u00e9questre"},"highway_bus_guideway":{"cz":"autobusov\u00e1 dr\u00e1ha","en":"bus guideway","de":"Spurbus","fr":"autobus guid\u00e9"},"highway_bus_stop":{"cz":"autobusov\u00e1 zast\u00e1vka","en":"bus stop","de":"Bushaltestelle","fr":"arr\u00eat de bus"},"highway_byway":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_Calle residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_cami":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_construction":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_construction_Project_under study . Not built yet":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_corridor":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_crossing":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_cycleway":{"cz":"cyklistick\u00e1 stezka","en":"cycleway","de":"Radwanderweg","fr":"piste cyclable"},"highway_cycleway;construction":{"cz":"cyklistick\u00e1 stezka","en":"cycleway","de":"Radwanderweg","fr":"piste cyclable"},"highway_cycleway;track":{"cz":"cyklistick\u00e1 stezka","en":"cycleway","de":"Radwanderweg","fr":"piste cyclable"},"highway_depot":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_destruction":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_disabled":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_disused":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_elevator":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_emergency_access_point":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_escape":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_footway":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_footway;residential":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_footway;track":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_ford":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_gallop":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_hole":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_ladder":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_lane":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_lift":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_living_street":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_living_street;residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_mini_roundabout":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_minor":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_motorway":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_motorway_junction":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_motorway_link":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_name_only":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_no":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_path":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_path;footway":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_path;track":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_path; via_ferrata":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_pedes":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_pedestrian":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_pedestrian;residential":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_pedestrian;unclassified":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_piste":{"cz":"ly\u017ea\u0159sk\u00e1 trasa","en":"piste","de":"Piste","fr":"piste de ski"},"highway_place":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_planned":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_platform":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_preproposed":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_primary":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_primary_link":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_proposal":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_proposed":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_PROPOSED":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_proposed-but-in-limbo-so-please-dont-render-for-now":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_raceway":{"cz":"z\u00e1vodn\u00ed dr\u00e1ha","en":"raceway","de":"Rennbahn","fr":"circuit automobile"},"highway_ramp":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential;construction":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential;cycleway":{"cz":"cyklistick\u00e1 stezka","en":"cycleway","de":"Radwanderweg","fr":"piste cyclable"},"highway_residential;footway":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_residential;living_street":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential;service":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential;track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential; track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential;unclassified":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_residential; unclassified":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_rest_area":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_rfe":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_road":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_secondary":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_secondary_link":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_service":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_Service":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_service;footway":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_service;residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_services":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_stepping_stones":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_steps":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_t":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_tank track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_tertiary":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_tertiary_link":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_tertiary;residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_tertiary;secondary":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_track;living_street":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_track;residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_track;service":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_track;unclassified":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_trail":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_trunk":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_trunk_link":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_turning_circle":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_turning_loop":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;living_street":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;residential":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;road":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;service":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;tertiary":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified;track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unclassified; track":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unknown":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_unsurfaced":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_via_ferrata":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_via_ferrata;path":{"cz":"stezka pro p\u011b\u0161\u00ed","en":"footway","de":"Fu\u00dfweg","fr":"voie pi\u00e9tonne"},"highway_virtual":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_wildlife_crossing":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_yes":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"highway_ype":{"cz":"komunikace","en":"road","de":"Verkehr","fr":"route"},"historic_castle":{"cz":"z\u00e1mek","en":"castle","de":"Burg, Schloss","fr":"ch\u00e2teau"},"historic_city_gate":{"cz":"br\u00e1na","en":"city gate","de":"Stadttor","fr":"porte de ville"},"historic_fort":{"cz":"pevnost","en":"fort","de":"Festung","fr":"fort"},"historic_place_of_worship":{"cz":"religiozn\u00ed stavba","en":"place of worship","de":"Kultst\u00e4tte","fr":"lieu de culte"},"historic_ruins":{"cz":"ruina","en":"ruins","de":"Ruinen","fr":"ruines"},"natural_beach":{"cz":"pl\u00e1\u017e","en":"beach","de":"Strand","fr":"plage"},"natural_cave_entrance":{"cz":"jeskyn\u011b","en":"cave","de":"H\u00f6hle","fr":"grotte"},"natural_cliff":{"cz":"\u00fates","en":"cliff","de":"Klippe","fr":"falaise"},"natural_glacier":{"cz":"ledovec","en":"glacier","de":"Gletscher","fr":"glacier"},"natural_peak":{"cz":"vrchol","en":"peak","de":"Spitze","fr":"pic"},"natural_protected_area":{"cz":"chr\u00e1n\u011bn\u00e9 \u00fazem\u00ed","en":"protected area","de":"Naturschutzgebiet","fr":"zone prot\u00e9g\u00e9e"},"natural_rock":{"cz":"sk\u00e1la","en":"rock","de":"Rock","fr":"rochers"},"natural_volcano":{"cz":"sopka","en":"volcano","de":"Vulkan","fr":"volcan"},"_locality":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_1220":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Abejuela-Bejis":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_aboned":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_allotments":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_archipelago":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_As Penizas":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_attraction":{"cz":"turistick\u00e1 atraktivita","en":"tourist attraction","de":"Touristenattraktion","fr":"attraction touristique"},"place_baserria":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_bay":{"cz":"z\u00e1liv","en":"bay","de":"Bucht","fr":"baie"},"place_Beaucarrs Farm":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_block":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_borough":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_building":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_bunker":{"cz":"bunkr","en":"bunker","de":"Unterstand","fr":"abri"},"place_cadastral area":{"cz":"\u010d\u00e1st obce","en":"district","de":"Kreis","fr":"quartier"},"place_Case Buscarini":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_city":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_confluence":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_continent":{"cz":"kontinent","en":"continent","de":"Kontinent","fr":"continent"},"place_costa":{"cz":"pob\u0159e\u017e\u00ed","en":"coast","de":"K\u00fcste","fr":"c\u00f4te"},"place_cottages":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_country":{"cz":"st\u00e1t","en":"country","de":"Staat","fr":"pays"},"place_county":{"cz":"region","en":"Region","de":"Region","fr":"r\u00e9gion"},"place_deserted_village":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_district":{"cz":"\u010dtvr\u0165","en":"district","de":"Bezirk","fr":"quartier"},"place_Dorf":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_El Toro":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_El Toro-Bejis":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_farm":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Farm":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_farm;collapsed":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_farmyard":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_fell":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_field":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_FIXME":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_forester":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Gangkofen, Rottal-Inn":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_gorge":{"cz":"sout\u011bska","en":"gorge","de":"Schlucht","fr":"gorge"},"place_Gr\u00fcnem\u00fchle-Blick":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Gundeldingen":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_hall_of_residence":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_ham":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_hamleet":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_hamlet":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_Hamlet":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_hamlete":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_hamlet_Eichberg":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_harbour":{"cz":"p\u0159\u00edstav","en":"port","de":"Port","fr":"port"},"place_Hausen AG":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Holybourne":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_house":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_H\u00fcnenberg Zythus":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_hut":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_is_in:village=Alcarr\u00e0s":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_is_in:village=Torres de Segre":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_island":{"cz":"ostrov","en":"island","de":"Insel","fr":"\u00eele"},"place_islet":{"cz":"ostrov","en":"island","de":"Insel","fr":"\u00eele"},"place_isolated":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_isolated dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_isolated_dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Isolated_dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_isolated_dwqelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_isolate_dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Kroaz ar Marichal":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_lac":{"cz":"jezero","en":"lake","de":"See","fr":"lac"},"place_La Coteruca":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_ll":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_locailty":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_locality":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Locality":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_localoty":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_location":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Londa":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_M\u00e4nnerspielplatz":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Markowa":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Mas Poncet":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Masseria Bavaro":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Mill Farm":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Monsindoli":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Montagnola":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Monte Tossal":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_moor":{"cz":"ba\u017eina","en":"moor","de":"Sumpf","fr":"lande"},"place_muncipality":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_municipality":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_Musrai":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_national_park":{"cz":"n\u00e1rodn\u00ed park","en":"national park","de":"Nationalpark","fr":"parc national"},"place_Naturschutzgebiet":{"cz":"chr\u00e1n\u011bn\u00e9 \u00fazem\u00ed","en":"protected area","de":"Naturschutzgebiet","fr":"zone prot\u00e9g\u00e9e"},"place_neighbourhood":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Neighbourhood":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_offices":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Open Road":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Paramui\u00f1o":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_parish":{"cz":"religiozn\u00ed stavba","en":"place of worship","de":"Kultst\u00e4tte","fr":"lieu de culte"},"place_Park, Teich":{"cz":"park","en":"park","de":"Park","fr":"parc"},"place_part of town":{"cz":"\u010dtvr\u0165","en":"district","de":"Bezirk","fr":"quartier"},"place_peninsula":{"cz":"poloostrov","en":"peninsula","de":"Halbinsel","fr":"p\u00e9ninsule"},"place_Peninsula":{"cz":"poloostrov","en":"peninsula","de":"Halbinsel","fr":"p\u00e9ninsule"},"place_place":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Place":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Playground":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_point":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_political_structure":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_quarter":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_region":{"cz":"region","en":"Region","de":"Region","fr":"r\u00e9gion"},"place_Renera":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_residence":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Residencial":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_rock":{"cz":"sk\u00e1la","en":"rock","de":"Rock","fr":"rochers"},"place_Saca\u00f1et":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Salzgitter":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Santa Marina":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_sea":{"cz":"mo\u0159e","en":"sea","de":"Meer","fr":"mer"},"place_single_dwelling":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Site of Special Scientific Interest":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_square":{"cz":"n\u00e1m\u011bst\u00ed","en":"square","de":"Platz","fr":"place"},"place_state":{"cz":"socha","en":"statue","de":"Statue","fr":"statue"},"place_subdivision":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_suburb":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Suburb":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_suburban":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_suburb;locality":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Teufelslay":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_town":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_undefined":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_Valle Scura":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_valley":{"cz":"\u00fadol\u00ed","en":"valley","de":"Tal","fr":"vall\u00e9e"},"place_Vent\u00edn":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_vicinity":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_village":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_village_additionality":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_vinyard":{"cz":"vinice","en":"vinyard","de":"Weinberg","fr":"vignoble"},"place_Vossloh":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_waterfall":{"cz":"vodop\u00e1d","en":"waterfall","de":"Wasserfall","fr":"cascade"},"place_Weins-Antone-M\u00fchle":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_winery":{"cz":"vinice","en":"winery","de":"Weinberg","fr":"domaine viticole"},"place_Wintersdorf":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_yes":{"cz":"lokalita","en":"locality","de":"Lokalit\u00e4t","fr":"lieu"},"place_yes;locality":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"place_yes;town":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"tourism_alpine_hut":{"cz":"turistick\u00e1 chata","en":"alpine hut","de":"Almh\u00fctte","fr":"refuge"},"tourism_attraction":{"cz":"turistick\u00e1 atraktivita","en":"tourist attraction","de":"Touristenattraktion","fr":"attraction touristique"},"tourism_gallery":{"cz":"galerie","en":"gallery","de":"Galerie","fr":"galerie d'art"},"tourism_museum":{"cz":"muzeum","en":"museum","de":"Muzeum","fr":"mus\u00e9e"},"tourism_theme_park":{"cz":"tematick\u00fd z\u00e1bavn\u00fd park","en":"theme park","de":"Themenpark","fr":"parc \u00e0 th\u00e8mes"},"tourism_viewpoint":{"cz":"vyhl\u00eddka","en":"view point","de":"Aussicht","fr":"point de vue"},"tourism_zoo":{"cz":"zoo","en":"zoo","de":"Zoo","fr":"zoo"},"train_halt":{"cz":"\u017eelezni\u010dn\u00ed zast\u00e1vka","en":"railway station","de":"Bahnhof","fr":"gare ferroviaire"},"train_station":{"cz":"\u017eelezni\u010dn\u00ed stanice","en":"railway station","de":"Bahnhof","fr":"gare ferroviaire"},"tram_tram_stop":{"cz":"tramvajov\u00e1 zast\u00e1vka","en":"tram stop","de":"Stra\u00dfenbahnhaltestelle","fr":"arr\u00eat de tramway"},"water_canal":{"cz":"vodn\u00ed kan\u00e1l","en":"canal","de":"Kanal","fr":"canal"},"water_river":{"cz":"\u0159eka","en":"river","de":"Fluss","fr":"rivi\u00e8re"},"water_riverbank":{"cz":"\u0159eka","en":"river","de":"Flussufer","fr":"rivi\u00e8re"},"water_water":{"cz":"vodstvo","en":"water","de":"Wasser","fr":"eau"},"world_channel":{"cz":"pr\u016fliv","en":"channel","de":"Kanal","fr":"canal"},"world_citycapital":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"world_citynormal":{"cz":"obec","en":"city, village","de":"Gemeinde","fr":"ville, village"},"world_coast":{"cz":"pob\u0159e\u017e\u00ed","en":"coast","de":"K\u00fcste","fr":"c\u00f4te"},"world_country":{"cz":"st\u00e1t","en":"country","de":"Staat","fr":"pays"},"world_dependent":{"cz":"z\u00e1visl\u00e9 \u00fazem\u00ed","en":"dependent territory","de":"Abh\u00e4ngiges Gebiet","fr":"territoire d\u00e9pendant"},"world_depression":{"cz":"prol\u00e1klina","en":"depression","de":"Depression","fr":"cuvette"},"world_desert":{"cz":"pou\u0161\u0165","en":"desert","de":"W\u00fcste","fr":"d\u00e9sert"},"world_fjord":{"cz":"fjord","en":"fjord","de":"Fjord","fr":"fjord"},"world_geoarea":{"cz":"region","en":"Region","de":"Region","fr":"r\u00e9gion"},"world_gorge":{"cz":"sout\u011bska","en":"gorge","de":"Schlucht","fr":"gorge"},"world_gulf":{"cz":"z\u00e1liv","en":"gulf","de":"Golf","fr":"golfe"},"world_inlet":{"cz":"z\u00e1liv","en":"inlet","de":"Meeresarm","fr":"bras de mer"},"world_island":{"cz":"ostrov","en":"island","de":"Insel","fr":"\u00eele"},"world_island group":{"cz":"souostrov\u00ed","en":"island group","de":"Inselgruppe","fr":"archipel"},"world_lake":{"cz":"jezero","en":"lake","de":"See","fr":"lac"},"world_mountain":{"cz":"vrchol","en":"peak","de":"Spitze","fr":"pic"},"world_pen\/cape":{"cz":"poloostrov","en":"peninsula","de":"Halbinsel","fr":"p\u00e9ninsule"},"world_peninsula":{"cz":"poloostrov","en":"peninsula","de":"Halbinsel","fr":"p\u00e9ninsule"},"world_plain":{"cz":"planina","en":"plain","de":"Flachland","fr":"plaine"},"world_plateau":{"cz":"n\u00e1horn\u00ed plo\u0161ina","en":"plateau","de":"Plateau","fr":"plateau"},"world_range\/mtn":{"cz":"poho\u0159\u00ed","en":"mountains","de":"Gebirge","fr":"montagnes"},"world_river":{"cz":"\u0159eka","en":"river","de":"Fluss","fr":"rivi\u00e8re"},"world_sea":{"cz":"mo\u0159e","en":"sea","de":"Meer","fr":"mer"},"world_sound":{"cz":"z\u00e1liv","en":"sound","de":"Bucht","fr":"baie"},"world_strait":{"cz":"\u00fa\u017eina","en":"strait","de":"Meerenge","fr":"d\u00e9troit"},"world_valley":{"cz":"\u00fadol\u00ed","en":"valley","de":"Tal","fr":"vall\u00e9e"},"building_":{"cz":"budova","en":"building","de":"Bau","fr":"b\u00e2timent"}}; this.lang = 'cs'; if (this.lang == 'cs') this.lang = 'cz'; this.elText = null; this.elTextSubmit = null; this.urlSearchResultIcon = 'http://www.cykloserver.cz/cykloatlas/srchitemico.php?id='; this.urlSearchResultIconSel = 'http://www.cykloserver.cz/cykloatlas/srchitemicoa.php?id='; this.searchMarkers = null; this.defZoomLevel = 13; this.contentId; this.isOn; this.pOnClose; this._create = function() { this.contentId = 'infoblock_search'; this.elText = document.getElementById('sidlo_text'); this.elTextSubmit = document.getElementById('inp-text-submit'); this.iconSearchResult = { externalGraphic: this.urlSearchResultIcon, //externalGraphicSel: this.urlSearchResultIconSel, graphicWidth: 39, graphicHeight: 32, graphicXOffset: -7, graphicYOffset: -20, cursor: 'pointer' }; this.searchMarkers = new Array(); this.pOnClose = jQuery.proxy(this.onClose, this); this.attachEvents(); //this.precacheImages(); } this.precacheImages = function() { for (var ti = 1; ti <= 20; ti++) jQuery.get(this.urlSearchResultIconSel + ti); } this.isGPS = function(str) { var match = str.match(/(\d+)(?:\s*)°(?:\s*)(\d+)(?:\s*)'(?:\s*)(\d+)(?:\s)*(?:\.|,)(?:\s*)(\d+)(?:\s*)"(?:\s*)(S|N)(?:\s|,)*(\d+)(?:\s*)°(?:\s*)(\d+)(?:\s*)'(?:\s*)(\d+)(?:\s)*(?:\.|,)(?:\s*)(\d+)(?:\s*)"(?:\s*)(E|W)/i); //" (just for the editor..) if (match) { return true; } var match = str.match(/(S|N)(?:\s*)(\d+)°(\d+)(?:\.|,)(\d+)'(?:\s|,)*(E|W)(?:\s*)(\d+)°(\d+)(?:\.|,)(\d+)'/i); if (match) { return true; } var match = str.match(/(\d+)(.|,)(\d+)(S|N),?\s*(\d+)(.|,)(\d+)(W|E)/); if (match) { return true; } var match = str.match(/(\d+)°(\d+)'(\d+)"(S|N),?\s*(\d+)°(\d+)'(\d+)"(W|E)/); //" (just for the editor..) if (match) { return true; } var match = str.match(/(S|N)(\d+)°(\d+).(\d+)',?\s*(W|E)(\d+)°(\d+).(\d+)'/); if (match) { return true; } return false; } this.searchGPS = function() { function DtoDMS(a) { var res = Math.floor(a); res+= "°"; var b = (a - Math.floor(a)) * 60; res+= (Math.floor(b) < 10)?("0" + Math.floor(b)):(Math.floor(b)); res+= "'"; var c = (b - Math.floor(b)) * 60; res+= (Math.floor(c) < 10)?("0" + Math.floor(c)):(Math.floor(c)); res+= '"'; return res; } this.clearResults(); var pos = this.sanitizeFullGPS(this.elText.value + " "); if (this.map.isInDefWorkingArea(pos)) { if (this.map.getZoom() != this.defZoomLevel) this.map.setZoom(this.defZoomLevel); this.map.panTo(pos); var rlat = DtoDMS(pos.lat); var rlng = DtoDMS(pos.lng); var founditems = ""; var search_bbox = new Array(); var search_bbox_index = 0; var search_bbox_gps = new Array(); founditems+= "GPS
"; founditems+= ""; founditems+= rlat + "N, " + rlng + "E
"; founditems+= "
"; founditems+= "
"; founditems+= "
"; var x = pos.lng; var y = pos.lat; var p = {px:x,py:y}; search_bbox[search_bbox_index] = p; search_bbox_index++; search_bbox_gps[search_bbox_gps.length] = p; var founditems_gps = founditems; founditems = ""; founditems = founditems_gps; var re = new RegExp("#G1#", "g"); founditems = founditems.replace(re, 1); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_gps[0].py, search_bbox_gps[0].px), 1); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); var html = founditems; if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = html; } var el = document.getElementById('srchitem' + 1); if (el) { el.cSearch = this; el.idSrchItem = 1; $(el).on("mouseover", this.onSrchResultItemMouseOver); $(el).on("mouseout", this.onSrchResultItemMouseOut); $(el).on("click", this.onSrchResultItemClick); } } else { if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = 'Zadaná souřadnice se nenachází v pracovní oblasti.'; } } } this.createSearchMarker = function(pos, i) { var icon = { externalGraphic: this.iconSearchResult.externalGraphic + i, externalGraphicHl: this.urlSearchResultIconSel + i, externalGraphicOrig: this.iconSearchResult.externalGraphic + i, graphicWidth: this.iconSearchResult.graphicWidth, graphicHeight: this.iconSearchResult.graphicHeight, graphicXOffset: this.iconSearchResult.graphicXOffset, graphicYOffset: this.iconSearchResult.graphicYOffset, cursor: this.iconSearchResult.cursor }; var marker = OLM.Markers.createMarker(pos, this.map, icon); marker.cSearch = this; marker.searchIndex = i; marker.highlight = function() { this.style.externalGraphic = this.attributes.style.externalGraphicHl; this.redraw(); } marker.unhighlight = function() { this.style.externalGraphic = this.attributes.style.externalGraphicOrig; this.redraw(); } marker.center = function() { this.cSearch.clickItem(this.searchIndex); } marker.onMouseOver = function(ev) { this.cSearch.selectItem(this.searchIndex); this.highlight(); } marker.onMouseOut = function(ev) { this.cSearch.unselectItem(this.searchIndex); this.unhighlight(); } marker.onMouseClick = function(ev) { this.center(); } return marker; } this.searchPlaces = function() { var t = this.elText.value; t = t.replace(/á/g, "a"); t = t.replace(/ä/g, "a"); t = t.replace(/č/g, "c"); t = t.replace(/ď/g, "d"); t = t.replace(/é/g, "e"); t = t.replace(/ě/g, "e"); t = t.replace(/ë/g, "e"); t = t.replace(/í/g, "i"); t = t.replace(/ň/g, "n"); t = t.replace(/ó/g, "o"); t = t.replace(/ö/g, "o"); t = t.replace(/ř/g, "r"); t = t.replace(/š/g, "s"); t = t.replace(/ť/g, "t"); t = t.replace(/ú/g, "u"); t = t.replace(/ů/g, "u"); t = t.replace(/ü/g, "u"); t = t.replace(/ý/g, "y"); t = t.replace(/ž/g, "z"); t = t.replace(/Á/g, "A"); t = t.replace(/Ä/g, "A"); t = t.replace(/Č/g, "C"); t = t.replace(/Ď/g, "D"); t = t.replace(/É/g, "E"); t = t.replace(/Ě/g, "E"); t = t.replace(/Ë/g, "E"); t = t.replace(/Í/g, "I"); t = t.replace(/Ň/g, "N"); t = t.replace(/Ó/g, "O"); t = t.replace(/Ö/g, "O"); t = t.replace(/Ř/g, "R"); t = t.replace(/Š/g, "S"); t = t.replace(/Ť/g, "T"); t = t.replace(/Ú/g, "U"); t = t.replace(/Ů/g, "U"); t = t.replace(/Ü/g, "U"); t = t.replace(/Ý/g, "Y"); t = t.replace(/Ž/g, "Z"); var url = "http://www.cykloserver.cz/cykloatlas/srchsidlo.php?sidlo=" + t; jQuery.ajax(url, {cache:false, complete:this.reqSearchPlacesComplete, context:this, error:this.reqSearchPlacesError, success:this.reqSearchPlacesSuccess, type:'GET'}); } this.reqSearchPlacesComplete = function() { } this.reqSearchPlacesSuccess = function(data) { this.clearResults(); var doc = data; var pts = new OpenLayers.Bounds(); if (doc.getElementsByTagName("item").length == 0) { if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = 'Nebyl nalezen žádný výsledek.'; } } else { var founditems = ""; var search_bbox = new Array(); var search_bbox_index = 0; var iss_lokality = false; var cntlok = 0; try { cntlok = doc.getElementsByTagName("lokality")[0].attributes.getNamedItem("count").value; iss_lokality = true; } catch (e) { } cntlok = ((cntlok > 10)?(10):(cntlok)); founditems = ""; if (iss_lokality) { var search_bbox_lok = new Array(); founditems+= "Lokality
"; var doclok = doc.getElementsByTagName("lokality")[0]; for (var ii = 0; ii < ((cntlok > 10)?(10):(cntlok)); ii++) { founditems+= ""; if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("lokalita")) founditems+= doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("lokalita").value + "
"; if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("okres")) founditems+= "Okres " + doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("okres").value; if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("stat")) { if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("okres")) founditems+= ", "; founditems+= doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("stat").value; } if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("okres") || doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("okres")) founditems+= "
"; var locTypeName = ''; if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("type")) locTypeName = doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("type").value + '_'; if (doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("subtype")) { locTypeName+= doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("subtype").value; } if (locTypeName != '') { if (this.locationTypeNames[locTypeName]) { if (this.locationTypeNames[locTypeName][this.lang]) { founditems+= this.locationTypeNames[locTypeName][this.lang] + "
"; } } } founditems+= "
"; var x = doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("x").value; var y = doclok.getElementsByTagName("item")[ii].attributes.getNamedItem("y").value; pts.extend(new OpenLayers.LonLat(x, y)); p = {px:x,py:y}; search_bbox[search_bbox_index] = p; search_bbox_index++; search_bbox_lok[search_bbox_lok.length] = p; } } var founditems_lokality = founditems; var iss_ulice = false; var cntuli = 0; try { cntuli = doc.getElementsByTagName("ulice")[0].attributes.getNamedItem("count").value; iss_ulice = true; } catch (e) { } cntuli = ((cntuli > 10)?(10):(cntuli)); founditems = ""; if (iss_ulice) { var search_bbox_uli = new Array(); if (founditems.length) founditems+= "
"; founditems+= "Ulice
"; var doculi = doc.getElementsByTagName("ulice")[0]; for (var ii = 0; ii < ((cntuli > 10)?(10):(cntuli)); ii++) { founditems+= ""; if (doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("ulice")) founditems+= doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("ulice").value + "
"; if (doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("obec")) founditems+= "Obec: " + doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("obec").value + "
"; if (doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("okres")) founditems+= "Okres " + doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("okres").value + "
"; founditems+= "
"; var x = doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("x").value; var y = doculi.getElementsByTagName("item")[ii].attributes.getNamedItem("y").value; pts.extend(new OpenLayers.LonLat(x, y)); p = {px:x,py:y}; search_bbox[search_bbox_index] = p; search_bbox_index++; search_bbox_uli[search_bbox_uli.length] = p; } } var founditems_ulice = founditems; var iss_adresy = false; var cntadr = 0; try { cntadr = doc.getElementsByTagName("adresy")[0].attributes.getNamedItem("count").value; iss_adresy = true; } catch (e) { } cntadr = ((cntadr > 10)?(10):(cntadr)); founditems = ""; if (iss_adresy) { var search_bbox_adr = new Array(); if (founditems.length) founditems+= "
"; founditems+= "Adresy
"; var docadr = doc.getElementsByTagName("adresy")[0]; for (var ii = 0; ii < cntadr; ii++) { founditems+= ""; if (docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("ulice")) founditems+= docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("ulice").value + " "; if (docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("cis_dom")) founditems+= docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("cis_dom").value; founditems+= "
" if (docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("obec")) founditems+= "Obec: " + docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("obec").value + "
"; if (docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("okres")) founditems+= "Okres " + docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("okres").value + "
"; founditems+= "
"; var x = docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("x").value; var y = docadr.getElementsByTagName("item")[ii].attributes.getNamedItem("y").value; pts.extend(new OpenLayers.LonLat(x, y)); p = {px:x,py:y}; search_bbox[search_bbox_index] = p; search_bbox_index++; search_bbox_adr[search_bbox_adr.length] = p; } } var founditems_adresy = founditems; founditems = ""; var str_sidlo = this.elText.value; // pokud retezec obsahuje cislo, zachazime s nim jako s adresou if (str_sidlo.search(/[0-9]/) >= 0) { founditems = founditems_adresy + founditems_ulice + founditems_lokality; var iindex = 1; if (iss_adresy) { for (var ti = 0; ti < cntadr; ti++) { var re = new RegExp("#A"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_adr[ti].py, search_bbox_adr[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } if (iss_ulice) { for (var ti = 0; ti < cntuli; ti++) { var re = new RegExp("#U"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_uli[ti].py, search_bbox_uli[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } if (iss_lokality) { for (var ti = 0; ti < cntlok; ti++) { var re = new RegExp("#L"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_lok[ti].py, search_bbox_lok[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } } // pokud retezec obsahuje carku a ne cislo, zachazime s nim jako s ulici if ((founditems.length == 0) && (str_sidlo.search(/,/) >= 0)) { founditems = founditems_ulice + founditems_lokality; var iindex = 1; if (iss_ulice) { for (var ti = 0; ti < cntuli; ti++) { var re = new RegExp("#U"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_uli[ti].py, search_bbox_uli[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } if (iss_lokality) { for (var ti = 0; ti < cntlok; ti++) { var re = new RegExp("#L"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_lok[ti].py, search_bbox_lok[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } } // pokud retezec neobsahuje carku ani cislo, zachazime s nim jako s lokalitou if ((founditems.length == 0) && (true)) { founditems = founditems_lokality + founditems_ulice + founditems_adresy; var iindex = 1; if (iss_lokality) { for (var ti = 0; ti < cntlok; ti++) { var re = new RegExp("#L"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_lok[ti].py, search_bbox_lok[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } if (iss_ulice) { for (var ti = 0; ti < cntuli; ti++) { var re = new RegExp("#U"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_uli[ti].py, search_bbox_uli[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } if (iss_adresy) { for (var ti = 0; ti < cntadr; ti++) { var re = new RegExp("#A"+(ti+1)+"#", "g"); founditems = founditems.replace(re, iindex); var tsearch_marker = this.createSearchMarker(new OLM.LatLng(search_bbox_adr[ti].py, search_bbox_adr[ti].px), iindex); this.searchMarkers.push(tsearch_marker); this.map.addMarker(tsearch_marker); iindex++; } } } var html = founditems; if (founditems.length) { if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = html; for (var ti = 0; ti < this.searchMarkers.length; ti++) { var el = document.getElementById('srchitem' + (ti + 1)); if (el) { el.cSearch = this; el.idSrchItem = ti + 1; $(el).on("mouseover", this.onSrchResultItemMouseOver); $(el).on("mouseout", this.onSrchResultItemMouseOut); $(el).on("click", this.onSrchResultItemClick); } } } this.map.showExtent(pts.left, pts.bottom, pts.right, pts.top); } else { if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = 'Nebyl nalezen žádný výsledek.'; } } } } this.reqSearchPlacesError = function() { } this.onSrchResultItemMouseOver = function() { this.cSearch.selectItem(this.idSrchItem); } this.onSrchResultItemMouseOut = function() { this.cSearch.unselectItem(this.idSrchItem); } this.onSrchResultItemClick = function(e) { this.cSearch.clickItem(this.idSrchItem); try { e.preventDefault(); } catch (e) { } return false; } this.selectItem = function(id, doNotUpdateMarker) { if (!doNotUpdateMarker) this.searchMarkers[id - 1].highlight(); document.getElementById('srchitem' + id).style.backgroundColor = "#E0E0FF"; } this.unselectItem = function(id, doNotUpdateMarker) { if (!doNotUpdateMarker) this.searchMarkers[id - 1].unhighlight(); document.getElementById('srchitem' + id).style.backgroundColor = ""; } this.clickItem = function(id) { if (this.map.getZoom() != this.defZoomLevel) this.map.setZoom(this.defZoomLevel); var p = this.searchMarkers[id - 1].geometry.clone(); var latLng = this.map.getLatLngFromLonLat(new OpenLayers.LonLat(p.x, p.y)); this.map.panTo(latLng); } this.onTextSubmitClick = function() { if (this.elText) { if (document.getElementById('search-obsah-inner')) { document.getElementById('search-obsah-inner').innerHTML = ''; } this.show(); //this.openSearchResults(); if (this.isGPS(this.elText.value)) { this.searchGPS(); } else { this.searchPlaces(); } } return false; } this.clearResults = function() { if (this.searchMarkers.length > 0) { for (var ti = 0; ti < this.searchMarkers.length; ti++) { this.map.removeMarker(this.searchMarkers[ti]); this.searchMarkers[ti] = null; } this.searchMarkers = new Array(); } } this.show = function() { this.map.cCaInfoBox.openInfoBox(this.contentId, this.pOnClose); this.isOn = true; } this.hide = function() { this.map.cCaInfoBox.hideInfoBox(); } this.onClose = function() { this.clearResults(); this.isOn = false; } this.attachEvents = function() { if (this.elTextSubmit) { $(this.elTextSubmit).bind('click', jQuery.proxy(this.onTextSubmitClick, this)); } } this.sanitizeFullGPS = function(str) { var match = str.match(/(\d+)(?:\s*)°(?:\s*)(\d+)(?:\s*)'(?:\s*)(\d+)(?:\s)*(?:\.|,)(?:\s*)(\d+)(?:\s*)"(?:\s*)(S|N)(?:\s|,)*(\d+)(?:\s*)°(?:\s*)(\d+)(?:\s*)'(?:\s*)(\d+)(?:\s)*(?:\.|,)(?:\s*)(\d+)(?:\s*)"(?:\s*)(E|W)/i); //" (just for the editor..) if (match) { var lat = parseFloat(match[1]) + (parseFloat(match[2]) + parseFloat(match[3] + '.' + match[4]) / 60) / 60; if ((match[5] == 'S') || (match[5] == 's')) lat*= -1; var lon = parseFloat(match[6]) + (parseFloat(match[7]) + parseFloat(match[8] + '.' + match[9]) / 60) / 60; if ((match[10] == 'W') || (match[10] == 'w')) lon*= -1; return new OLM.LatLng(lat, lon); } var match = str.match(/(S|N)(?:\s*)(\d+)°(\d+)(?:\.|,)(\d+)'(?:\s|,)*(E|W)(?:\s*)(\d+)°(\d+)(?:\.|,)(\d+)'/i); if (match) { var lat = parseFloat(match[2]) + parseFloat(match[3] + '.' + match[4]) / 60; if ((match[1] == 'S') || (match[1] == 's')) lat*= -1; var lon = parseFloat(match[6]) + parseFloat(match[7] + '.' + match[8]) / 60; if ((match[5] == 'W') || (match[5] == 'w')) lon*= -1; return new OLM.LatLng(lat, lon); } var match = str.match(/(\d+)(.|,)(\d+)(S|N),?\s*(\d+)(.|,)(\d+)(W|E)/); if (match) { var lat = parseFloat(match[1] + '.' + match[3]); if (match[4] == 'S') lat*= -1; var lon = parseFloat(match[5] + '.' + match[7]); if (match[8] == 'W') lon*= -1; return new OLM.LatLng(lat, lon); } var match = str.match(/(\d+)°(\d+)'(\d+)"(S|N),?\s*(\d+)°(\d+)'(\d+)"(W|E)/); //" (just for the editor..) if (match) { var lat = parseInt(match[1]) + parseInt(match[2]) / 60 + parseInt(match[3]) / 3600; if (match[4] == 'S') lat*= -1; var lon = parseInt(match[5]) + parseInt(match[6]) / 60 + parseInt(match[7]) / 3600; if (match[8] == 'W') lon*= -1; return new OLM.LatLng(lat, lon); } var match = str.match(/(S|N)(\d+)°(\d+).(\d+)',?\s*(W|E)(\d+)°(\d+).(\d+)'/); if (match) { var lat = parseInt(match[2]) + parseFloat(match[3] + '.' + match[4]) / 60; if (match[1] == 'S') lat*= -1; var lon = parseInt(match[6]) + parseFloat(match[7] + '.' + match[8]) / 60; if (match[5] == 'W') lon*= -1; return new OLM.LatLng(lat, lon); } return new OLM.LatLng(-999, -999); } this.onMarkerSearchResultMouseOver = function() { this.parentCtrl.selectItem(this.idres); } this.onMarkerSearchResultMouseOut = function() { this.parentCtrl.unselectItem(this.idres); } this.onMarkerSearchResultClick = function() { this.parentCtrl.clickItem(this.idres); } this._create(); }