I know only part of this question is relevant to Open Layers. I am using Open
Layers with some layers served by Geoserver. I have a python script that
takes user input from the web page, and returns a GeoJSON file. What is the
best way to use a python script to accomplish this? Is there a preferred
method for where I put the python script, and call it in a Geoserver/Open
Layers framework?
I would get a basic tutorial on how to create a web application. What development environment (netbeans, eclipse,?) are you using to create your deployment WAR? The short answer is that you have your webpage, myapp.html. Your scripts normally would be in a subdirectory of the directory that is in. My webapp directory usually looks something like this.
webapps/myapp
                   index.html
                  /css
                  /images
/scripts -> this is where I put serverside part of application
                  /META-INF
                  /WEB-INF

The full url for the script is thus myserver/myapp/scripts/myscript.py but your app can refer to it as scripts/myscript.py and not worry about absolute location (so it works on development machine, test server and production server without alteration).

The development environment usually builds the minimal structure for you. If your script is being shared between multiple applications you may want a global context to locate it in but setting that up is highly dependent on what server you use.

Notice: This email and any attachments are confidential.
If received in error please destroy and immediately notify us.
Do not copy or disclose the contents.

_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to