X-Git-Url: https://sipb.mit.edu/gitweb.cgi/ikiwiki.git/blobdiff_plain/96a8ea0ebbd93a8cc56222234d4a5815b30a3934..60188d728080c3e558b647d7595ea376944f51d0:/doc/bugs/po:_apache_config_serves_index.rss_for_index.mdwn diff --git a/doc/bugs/po:_apache_config_serves_index.rss_for_index.mdwn b/doc/bugs/po:_apache_config_serves_index.rss_for_index.mdwn index e6e1b57a8..a2b68c4b1 100644 --- a/doc/bugs/po:_apache_config_serves_index.rss_for_index.mdwn +++ b/doc/bugs/po:_apache_config_serves_index.rss_for_index.mdwn @@ -11,8 +11,8 @@ Analysis: * /etc/mime.types gives mime types to .rss and .atom files * `mod_negotiation`'s MultiViews allows any file with a mime type to be served up via content negotiation, if the client requests that type. -* wget etc send "Accept: */*" to accept all content types. Compare - with firefox, which sends "Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*" +* wget etc send `Accept: */*` to accept all content types. Compare + with firefox, which sends `Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*` * So apache has a tie between a html encoded Enlish file, and a rss encoded English file and the client has no preference. In a tie, apache will serve up the *smallest* file, which tends to be the rss file. (Apache's docs say it uses that @@ -26,3 +26,11 @@ I wonder if it would be worth making the po plugin generate apache [type map files](http://httpd.apache.org/docs/2.0/mod/mod_negotiation.html#typemaps). That should avoid this problem. --[[Joey]] + +Update: A non-intrusive fix is to add this to apache configuration. +This tunes the "quality" of the rss and atom files, in an apparently currently +undocumented way (though someone on #httpd suggested it should get documented). +Result is that apache will prefer serving index.html. --[[Joey]] [[done]] + + AddType application/rss+xml;qs=0.8 .rss + AddType application/atom+xml;qs=0.8 .atom