Example 1.8: Changing the Map's Output Format
Depending on the format you choose, the image may not display on your browser. If the link fails to display on your browser, right click on the graphic above and save the link as whatever format you specified on your mapfile.
Here's the mapfile (Example1-8.map):
Our mapfile now contains a new object, OUTPUTFORMAT. This object is defined within the MAP object and is used in conjunction with the IMAGETYPE keyword. Depending on the libraries you compiled with MapServer, you can have several output format choices--the GD library provides PNG (8- and 24-bit), GIF, JPEG, and WBMP; the GDAL library, a source for many of MapServer's input formats, can also provide output to PNG, JPEG, TIFF/GeoTIFF, and other raster formats; the PDFLib library provides PDF output; and the MING library provides Flash output. Have a look at the OUTPUTFORMAT object and experiment by changing the IMAGETYPE keyword on you mapfile. The NAME of your OUTPUT format should be used as your IMAGETYPE value (ex: IMAGETYPE png or IMAGETYPE png24).
Please consult the OUTPUTFORMAT object reference at: