<br><font size=2 face="sans-serif">Steve,</font>
<br>
<br><font size=2 face="sans-serif">Is there any GeoJSON example I can see?
I must be missing something trivial,</font>
<br>
<br><font size=2 face="sans-serif">When I put:</font>
<br>
<br><font size=2 face="sans-serif">OUTPUTFORMAT</font>
<br><font size=2 face="sans-serif">&nbsp; NAME 'geojson'</font>
<br><font size=2 face="sans-serif">&nbsp; DRIVER TEMPLATE</font>
<br><font size=2 face="sans-serif">&nbsp; MIMETYPE 'application/json; subtype=geojson'</font>
<br><font size=2 face="sans-serif">&nbsp; TEMPLATE 'myTemplate.js'</font>
<br><font size=2 face="sans-serif">END</font>
<br>
<br><font size=2 face="sans-serif">in my.map file and call for example
&quot;http://localhost/cgi-bin/mapserv.exe?map=/ms4w/apps/pmapper/pmapper-3.2.0/config/default/geojson_demo.map&amp;layer=countries&quot;
(this works correctly without geojson part), I get: </font><font size=3>getString():
Symbol definition error. Parsing error near (TEMPLATE):(line 74) </font>
<br>
<br><font size=2 face="sans-serif">If I put DRIVER 'TEMPLATE' then I get:
</font><font size=3>loadOutputFormat(): Unknown identifier. Parsing error
near (TEMPLATE):(line 76) </font>
<br>
<br><font size=2 face="sans-serif">Finally, putting </font><tt><font size=2>FORMATOPTION
'FILE=myTemplate.js'</font></tt><font size=2 face="sans-serif"> instead
of TEMPLATE gives me: </font><font size=3>loadOutputFormat(): General error
message. OUTPUTFORMAT clause references driver TEMPLATE, but this driver
isn't configured. </font>
<br>
<br><font size=2 face="sans-serif">So, I am obviously doing something wrong
regardless the myTemplate.js file? (anyway, can you give me an example
.js file, anything that could help :-)</font>
<br>
<br><font size=2 face="sans-serif">regards, dejan</font>
<br><tt><font size=2>&quot;Steve Lime&quot; &lt;Steve.Lime@dnr.state.mn.us&gt;
wrote on 02.07.2009 15:35:28:<br>
<br>
&gt; What does myTemplate.js look like?<br>
&gt; <br>
&gt; &gt;&gt;&gt; &lt;Dejan.Gambin@pula.hr&gt; 07/02/09 5:33 AM &gt;&gt;&gt;<br>
&gt; Thanks Fabio,<br>
&gt; <br>
&gt; As I said in my last post, I can't get GeoJSON output using this <br>
&gt; outputformat:<br>
&gt; <br>
&gt; OUTPUTFORMAT<br>
&gt; &nbsp; NAME 'geojson'<br>
&gt; &nbsp; DRIVER 'TEMPLATE'<br>
&gt; &nbsp; MIMETYPE 'application/json; subtype=geojson'<br>
&gt; &nbsp; FORMATOPTION 'FILE=myTemplate.js'<br>
&gt; END<br>
&gt; <br>
&gt; :-(<br>
&gt; <br>
&gt; regards, dejan<br>
&gt; <br>
&gt; Fabio D'Ovidio &lt;fabiodovidio@gmail.com&gt; wrote on 02.07.2009
09:28:06:<br>
&gt; <br>
&gt; &gt; Hi,<br>
&gt; &gt; <br>
&gt; &gt; Dejan.Gambin@pula.hr ha scritto:<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; Fabio,<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; Glad to here you are here too :-)<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; I can certainly use both GeoServer and MapServer but this
is not <br>
&gt; &gt; &gt; something I would like at the end. Since I am still investigating
all <br>
&gt; &gt; &gt; this, I am not in such a hurry to get it working with my
data ASAP. <br>
&gt; &gt; &gt; So, I would rather go with one of your Mapserver solutions.<br>
&gt; &gt; It is not so difficult...just 2, 3 minutes to load your layer
in <br>
&gt; &gt; GeoServer ;-)<br>
&gt; &gt; <br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; My first question, to be sure - so MapOl reads/gets the
GeoJSON data <br>
&gt; &gt; &gt; from Geoserver WFS and outputs GeoJSON data to WebClient?
If I <br>
&gt; &gt; &gt; understand Steve correctly, there is no way currently to
get GeoJSON <br>
&gt; &gt; &gt; output from MapServer WFS, only with CGI? So we come to
your solution <br>
&gt; 2.<br>
&gt; &gt; <br>
&gt; &gt; If you want to use the second solution you must create the HTTP
string <br>
&gt; &gt; to get GeoJSON from CGI-MapServer and than you must change MapOl
request <br>
&gt; <br>
&gt; &gt; to receive data and read them.<br>
&gt; &gt; If you want send me the URL and I'll send you the new MapOl as
soon as <br>
&gt; &gt; possbile!<br>
&gt; &gt; <br>
&gt; &gt; <br>
&gt; &gt; -- <br>
&gt; &gt; Fabio D'Ovidio<br>
&gt; &gt; Geospatial solutions<br>
&gt; &gt; <br>
&gt; &gt; Inova S.r.l.<br>
&gt; &gt; Web : http://www.inovaos.it<br>
&gt; &gt; GeoBI Blog: www.geobi.org<br>
&gt; &gt; Tel.: 081 197 57 600<br>
&gt; &gt; mail: fabiodovidio@gmail.com, f.dovidio@inovaos.it<br>
&gt; &gt; skype: dovidio_fa<br>
&gt; &gt; <br>
&gt; <br>
</font></tt>