[OpenLayers-Users] URL too long for IE mergeNewParams &
MapServer replacement variable
Andreas Hocevar
ahocevar at opengeo.org
Mon Jul 6 03:30:12 EDT 2009
Hi,
POST is not possible, because map tiles are loaded into <img/>
elements. What you could do, however, is use CQL filters instead of
SQL strings. These are usually shorter. Not sure if Mapserver supports
these though.
Another thing you could do is use OGC filters and build an SLD
dynamically. If you use PHP already, you will also have a session
scope. You can post the SLD, and when you get the response from the
server refresh your layer, which would access the sld associated with
the user session. You can do this by setting an SLD param on the layer
in OpenLayers, just pointing to a url (e.g.
http://localhost/mysld.php?PHP_SID=mysessionid).
Regards,
Andreas.
On Fri, Jul 3, 2009 at 8:28 PM, karsten vennemann<karsten at terragis.net> wrote:
> I have set-up a a dynamic layer with Mapserver and OpenLayers based on a
> user defined query of data.
>
> In my Mapserver file I have defined a PostGIS layer with a replacement
> variable. The user fills in values in a query builder html form, the
> resulting SQL string is sent via POST to a PHP page containing the
> OpenLayers map. Using mergeNewParams the SQL string is merged into the the
> request for the layer, MapServer handles the replacement variable and the
> dynamic layers is displayed correctly. So far this works great in Firefox
> but for the most complicated queries coming out of the query builder the SQL
> string is becoming very long and the request by Openlayers to display the
> layer will exceed 2048 characters (the apparent limit for IE 7) - thus
> breaking the application...
>
> Here is my question how can I set this up so that it is still working also
> in IE (preferably without changing the data base column names and without
> using MapScript).
> Is there a way that I can use POST instead of GET to transmit the SQL string
> to MapServer somehow. Any other ideas how I can get this done ?
>
> Karsten Vennemann
> Seattle, USA
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>
--
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.
More information about the Users
mailing list