How to do it...

Carry out the following steps:

  1. Create a new file named wfst.html. Open it and add the <head> and <body> tags. In the <head> tag, import the following OpenLayers library:
        <html> 
          <head> 
            <title>Consuming a WFS-T with OpenLayers</title> 
            <script              src="http://openlayers.org/api/OpenLayers.js">            </script> 
          </head> 
          <body> 
          </body> 
        </html> 
  1. Add a <div> tag in the <body> tag to contain the OpenLayers map, as shown in the following code; the map will have a width of 700 pixels and a height of 400 pixels:
        <div style="width:700px; height:400px" id="map"></div>
  1. Just after the <div> tag is made to contain the map, add a JavaScript script. Inside the script, start setting ProxyHost to the web location where you deployed your proxy script. ...

Get PostGIS Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.