[fusion-dev] How to create a Fusion javascript file
Rachot Moragraan
moo at ci.garden-grove.ca.us
Tue Jun 12 08:01:57 PDT 2012
This is just my take:
maybe create a widget that can be activated with a click of a button on the toolbar. most likely you dont want this feature to *always* be activated anyways right? You can see how to create a widget by copying other widgets in Fusion.
In your widget, once activated, create a listener for user's click. Convert that click into a geocordinate (you can see plenty of this method in other widgets also, i think. PixToGeo or something like that). Then pass that (along with the mapname and session id) to a PHP script via AJAX that creates a temporary session point layer then refreshes the map. This will draw that point on the map.
>From there, you can do more AJAX calls to a PHP script to run queries on that point layer against other layers.
It's a rough strategy...
----- Original Message -----
From: "swimming" <sshengqi at gmail.com>
To: fusion-dev at lists.osgeo.org
Sent: Wednesday, June 6, 2012 2:36:44 PM
Subject: [fusion-dev] How to create a Fusion javascript file
Hi
How to create a Fusion in Javascript file. I know it combined with
OpenLayer, Fusion and Jx. So I just read the MapGuide Fusion tutorial, most
of the javascript files from map server 2013. Still feel frustrated to just
create a js file and xml file at client side.
My specific task is not very complicated: customer click on my map-> a point
layer created->pass the coordinates to server side->create a layer in server
side->do the query between this point layer with all the other existing
layers. Right now I am stuck on the first step: create a js file that can
display on the map and pass these value to server side. Any suggestion?
Thank you.
--
View this message in context: http://osgeo-org.1560.n6.nabble.com/How-to-create-a-Fusion-javascript-file-tp4979596.html
Sent from the Fusion Developers mailing list archive at Nabble.com.
_______________________________________________
fusion-dev mailing list
fusion-dev at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fusion-dev
More information about the fusion-dev
mailing list