[OpenLayers-Users] OpenLayers.loadUrl is not a function

Manuel Fortes mfortesbesada at gmail.com
Fri Mar 18 13:25:43 EDT 2011


Hi,

I have a problem:

The code is:

function localizarAlter(wfsurl) {
rutaurl = wfsurl;
OpenLayers.loadUrl(rutaurl,'',null,highlight_them);
}

function highlight_them(response) {
features = new OpenLayers.Format.GML().read(responseText);
map.zoomToExtent(features[0].geometry.getBounds());
}

In a php file I have this script code:

window.opener.localizarAlter('
http://localhost/cgi-bin/mapserv.exe?map=c:/ms4w/Apache/htdocs/aplicatiuPla/mapfiles/08alternativas.map&service=wms&version=1.1.1&request=getmap&width=600&height=500&bbox=459533,260506,481708,270001&format=png&layers=pozos,captacion,depBombeo,depDistrib,pozoCant,cantareras,tupCapt,tubAducc,tubImpuls,tubDistrib&SRS=EPSG:26716&sld=http://localhost/aplicatiuPla/php/prueba.xml');

This call works, but the problem is something is wrong with the functions,
because when I execute the file, the firefox firebug shows an error:
OpenLayers.loadUrl is not a function.

Could anybody help me? I'm a newbie and I don't know how can solve it by
myself. Thanks in advance,

Manuel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20110318/566aa534/attachment-0001.html


More information about the Users mailing list