<div dir="ltr"><div>I've been struggling with the JSON template errors described in my April 3 email below. Initially I was blaming it on different computers. Now I think it is related to the MIMETYPE in the OUTPUTFORMAT block. This block fails with "Malformed <span class="">template</span> name (dummy)"<br>
<br>OUTPUTFORMAT<br>  NAME "geojson"<br>  DRIVER "TEMPLATE"<br>  MIMETYPE 'application/json; subtype=geojson'<br>  FORMATOPTION "FILE=templates/json.js"<br>END<br><br></div>this block works (mimetype is removed)<br>
<div><br>OUTPUTFORMAT<br>  NAME "geojson"<br>  DRIVER "TEMPLATE"<br>  FORMATOPTION "FILE=templates/json.js"<br>END<br><br></div><div>I'm still not 100% sure that I have this backed into a corner yet. <br>
<br>So is<br>   MIMETYPE 'application/json; subtype=geojson'<br></div><div>incorrect? I've tried various other mimetypes to specify JSON output and all fail, however "text/html" works.<br><br></div><div>
I don't understand the relationship between mimetype and a "Malformed <span class="">template</span> name". Why do I get that error for an invalid mimetype?<br><br></div><div>Thanks,<br>Rich<br></div><div><br>
</div><div><br><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 3, 2014 at 8:33 AM, Richard Greenwood <span dir="ltr"><<a href="mailto:richard.greenwood@gmail.com" target="_blank">richard.greenwood@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>I have two very similar computers. On one JSON templates work, the other not. The not-working one displays "Malformed template name (dummy)" where "dummy" is a non-existent file and the non-working version seems to ignore the OUTPUTFORMAT block. For example I can put invalid parameters in the block and they don't throw errors whereas on my working computer they do.<br>

<br></div>So I'm wondering if there are any dependencies at either compile or run time that I'm missing. My working computer is Fedora with MapServer installed from a repo, my non-working computer is Amazon Linux (at Redhat derivative) with MapServer 6.0 and 6.2 built from source. <br>

<br></div>Thanks,<br>Rich<span class="HOEnZb"><font color="#888888"><br><div><div><div><div><br>-- <br>Richard Greenwood<br><a href="mailto:richard.greenwood@gmail.com" target="_blank">richard.greenwood@gmail.com</a><br>
<a href="http://www.greenwoodmap.com" target="_blank">www.greenwoodmap.com</a>
</div></div></div></div></font></span></div>
</blockquote></div><br><br clear="all"><br>-- <br>Richard Greenwood<br><a href="mailto:richard.greenwood@gmail.com">richard.greenwood@gmail.com</a><br><a href="http://www.greenwoodmap.com">www.greenwoodmap.com</a>
</div></div>