Home

Bug report, various web servers

November 27, 2009

I’m trying to get graphics handled nicely (for at least Safari and Firefox), and it appears that web servers are behind the times.

Plan A, was to put up PDF files, which display great in Safari, but not at all in Firefox.

Plan B was to put up SVG files:

gs -sDEVICE=svg -dNOPAUSE -sOutputFile=`basename $1 .pdf`.svg $1 < /dev/null

but they were really big.

Plan C was to put up compressed GZ files (.svgz), but despite claims all over the web that this was the way to do it, it didn’t work, either in Firefox, or in Safari. However, Apache configuration is notoriously arcane and horrible.

The web server that handles these requests:

https://dl.dropbox.com/u/54487271/SVGTest.html

https://dl.dropbox.com/u/54487271/HV_ctlr_6_crystal_imon_filled.svgz

needs to include the Apache equivalent of

    AddEncoding x-gzip .svgz

I have tested this fix on my own laptop, running MacPorts Apache2,
serving files from my local disk. Failing to include that directive
yields either (for the direct reference to the svgz file)

This page contains the following errors:

error on line 1 at column 1: Encoding error
Below is a rendering of the page up to the first error.

or little broken-graphic boxes if they are embedded.

The MIME type IS being set correctly, but the compression is not.

One Response to “Bug report, various web servers”


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: