Autor Zpráva
Alesek
Profil *
Ahoj..prosim o pomoc..
vlozil jsem mapu od seznam.cz
<script type="text/javascript" src="http://api4.mapy.cz/loader.js"></script>
<script type="text/javascript">Loader.load();</script>
<div id="mapa" style="width:300px; height:200px; margin-top:20px;"></div>
<script type="text/javascript">
    var center = SMap.Coords.fromWGS84(16.21608378493283,50.1238049542549);
    var mapa = new SMap(JAK.gel("mapa"), center,15);
    mapa.addDefaultLayer(1).enable();
    mapa.addDefaultControls();
    var node = JAK.mel("a",{href:"http://mapy.cz/s/2BX6",target:'_blank'},{fontSize:"13px",lineHeight:"100%",fontFamily:"Arial,Verdana,sans-serif",textAlign:"center",display:"block",width:"165px", height:"33px",overflow:"hidden",textDecoration:"none",background:"transparent url(http://api4.mapy.cz/img/web/button-zobrazit.png) no-repeat",position:"absolute",left:"4px",bottom:"26px"});
    node.innerHTML = '<span style="position:relative; top:10px;text-shadow:0px 1px 1px #fff;color:#000;display:inline-block;padding-left:18px;background:transparent url(http://api4.mapy.cz/img/web/ico-zobrazit.png) 0 0 no-repeat">Zobrazit na Mapy.cz</span>';
    JAK.gel("mapa").appendChild(node);
    var layer = new SMap.Layer.Marker();
    mapa.addLayer(layer);
    layer.enable();
    var markerCoord = SMap.Coords.fromWGS84(16.21608378493283,50.1238049542549);
    var marker = new SMap.Marker(markerCoord,"MyMarker",{url:SMap.CONFIG.img + "/marker/drop-blue-asterisk.png"});
    layer.addMarker(marker);
</script>


validator mi vyhodil chybu

document type does not allow element "span" here

…4.mapy.cz/img/web/ico-zobrazit.png) 0 0 no-repeat">Zobrazit na Mapy.cz</span>';
Str4wberry
Profil
Viz Zápis javascriptu
Alesek
Profil *
Str4wberry:
Děkuju moc pane Jahoda :D pomohlo to.

Vaše odpověď


Prosím používejte diakritiku a interpunkci.

Ochrana proti spamu. Napište prosím číslo dvě-sta čtyřicet-sedm:

0