[OpenLayers-Users] loadURL: abort

Eric Lemoine eric.c2c at gmail.com
Wed Feb 20 15:06:55 EST 2008


On Tue, Feb 19, 2008 at 10:49 PM, Guillaume Sueur
<guillaume.sueur at neogeo-online.net> wrote:
> hmm, just tried :
>  AjaxTransfert = OpenLayers.loadURL("proxy.py?nom=" +
>  f.attributes["nom"],"",null,getDetails);
>
>  AjaxTransfert is always undefined as the loadURL function doesn't seem
>  to return anything.

What OL version are you using? In trunk OpenLayers.loadURL does return
an object with a transport property on which you can call abort. If
the version you're using doesn't have that you can probably use that
instead:

var request = new OpenLayers.Ajax.Request(url);
and then do request.transport.abort().

Hope this helps,
--
Eric



More information about the Users mailing list