autoindex xml support proposition
Maxim Dounin
mdounin at mdounin.ru
Wed Jul 10 16:31:23 UTC 2013
Hello!
On Wed, Jul 10, 2013 at 06:35:59PM +0300, Volodymyr Kostyrko wrote:
> Hi all.
>
> I recently played a bit with generating autoindex as XML and
> rendering it via XSL. The rough patch is here:
> http://limbo.xim.bz/ngx_http_autoindex_module.diff
>
> You can point http://limbo.xim.bz/ to look how it works and to get
> sample XSL and CSS.
>
> TODO:
> * correct content size calculation (I think I would need help with
> this one...);
> * draw a link to a parent directory.
>
> I know I'm generally bad at C but I tried to finalize DTD at first place.
>
> Comments welcome.
I fully support moving this toward XML as will allow various
customizations, but I can't say I like the patch.
One simple thing which catched my eye - please use distinct
directive to activate XML output, don't abuse "autoindex" switch.
Some more comments, in no particular order:
- It would be cool if we'll be able to provide an autoindex XML
output which is (X)HTML at the same time and works fine without
xslt processing.
- It looks like the code assumes client-side xslt processing as
the only option. We have the xslt module though, and it would
be fine to do server-side processing.
--
Maxim Dounin
http://nginx.org/en/donation.html
More information about the nginx-devel
mailing list