[Cartoweb-users] Geoloc coordinates in a new window
Oliver Christen
oliver.christen at camptocamp.com
Wed Sep 10 07:07:08 EDT 2008
well, simply open any plugin or coreplugin php file and look at the class declaration.
then you use the renderForm function, example in pretty much all plugin or coreplugin
if you intend to use ajax, your class must also implement Ajaxable, then you can use the ajaxGetPluginResponse function, example in pretty much all plugin or coreplugin too
----- Original Message -----
From: Valerio Noti
To: Oliver Christen
Cc: cartoweb-users at lists.maptools.org
Sent: Wednesday, September 10, 2008 9:37 AM
Subject: Re: [Cartoweb-users] Geoloc coordinates in a new window
Oliver,
not able to do this. Could you point me to some sample code (in wiki or somewhere else)?
Thank you
Valerio
2008/9/9 Oliver Christen <oliver.christen at camptocamp.com>
Hi
the plugin class must implements GuiProvider, then you can output variable to the template and, if you want, trigger some javascript.
regards
Oliver
----- Original Message -----
From: Valerio Noti
To: cartoweb-users at lists.maptools.org
Sent: Tuesday, September 09, 2008 12:17 PM
Subject: [Cartoweb-users] Geoloc coordinates in a new window
Hi all,
I installed geoloc plugin and works fine.
I'd like to show coordinates in a new window instead of an alert message.
In geoloc php file I commented this line:
// $this->getCartoclient()->addMessage('geo_x='.$this->Geo_x.',geo_y='.$this->Geo_y);
Where (and how) can I write a javascript window.open method and pass to the new window Geo_x and Geo_y
parameters?
I tried without success to insert it in renderFormPrepare function:
return array('geoloc_active' => $this->pluginStatus,
'geo_x' => $this->Geo_x,
'geo_y' => $this->Geo_y);
//open a new window...
........
Thanks in advance
Valerio
--------------------------------------------------------------------------
_______________________________________________
Cartoweb-users mailing list
Cartoweb-users at lists.maptools.org
http://lists.maptools.org/mailman/listinfo/cartoweb-users
--
/*
Valerio Noti
*/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/cartoweb-users/attachments/20080910/7e0ebd90/attachment-0001.html
More information about the Cartoweb-users
mailing list