[mapserver-users] Forcing WMS errors in XML-format in PHP-MapScript

Daniel Morissette dmorissette at mapgears.com
Tue Mar 16 09:05:02 EDT 2010

Jan Hartmann wrote:
> This is probably something I should try to look up myself, but perhaps 
> someone on this list has a quick answer.
>  I'm generating WMS output completely from  PHP MapScript (essentially 
> to make non-projected raster files available for WMS clients under a 
> fake projection number, to georeference raw coordinates). If something 
> goes wrong with the getCapabilities request, I would like to output a 
> valid XML error string that can be understood by regular WMS clients. 
> Any pointers to documentation on the required/optional XML formats?

I guess the best reference will be the WMS spec document itself, for the 
version of WMS that you are implementing. The spec docs are available at 

If you look at the WMS 1.1.1 doc from that list, section 6.7 discusses 
service exceptions and Annex A contains the XML exception DTD as well as 
an exception example.

Daniel Morissette

More information about the mapserver-users mailing list