[luci] lucid gives application/octet-stream to .xsl files.
Loren Stafford
lstafford at ubicom.com
Thu Sep 10 01:34:09 CEST 2009
How can I set the " extension to content-type " mappings in lucid?
When Ajax code in a browser tries to fetch an XSL file (say
"transform.xsl"), lucid returns the file with a content-type of
application/octet-stream. The browser (FireFox, in this case) fails to
proceed with the transformation, apparently (no error messages) because
the file does not have the expected type (text/xml or application/xml).
I have worked around this by serving the XSL file through a function
that sets the content-type. But is there no cleaner way?
One of the 3rd-party applications that we have built into OpenWrt, sends
its status as XML, so I chose to process that XML on the client side
with the browser's XSL engine. I could have transformed the file on the
server side with xsltproc, but then I would have to add xsltproc to the
firmware.
-- Loren
More information about the luci
mailing list