You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by "Zhang Weiwu, Beijing" <zh...@realss.com> on 2011/03/09 04:29:09 UTC

[users@httpd] multiviews doesn't work on index pages (and DirectoryIndex properly configured)

Hello. Debian 5.0, apache 2 2.2.9-10. I've optioned multiviews, and it
works perfectly fine for every document except index page.

All site using URIs without file extension names, every URI map to 2
files. e.g. about_us have 2 corresponding files:

about_us.en.html
about_us.de.html

And accessing /about_us gets the right language according to browser
setting, works perfectly.

Problem being the index page shows up as a blank page. More tests shows:

                       Firefox       w3m          wget
http://mysite          blank page    blank page   English page
http://mysite/index    English page  English page English page


How can I get http://mysite show non-blank page?


Here is my related section of configuration

	<Directory /var/www/www.realss.com.cn/htdocs/>
		Options FollowSymLinks MultiViews +Includes
		DirectoryIndex index
		AllowOverride All
		Order allow,deny
		allow from all
		AddHandler server-parsed .shtml
		SSITimeFormat "%S"
		XBitHack on
		Header append Vary cookie 
	</Directory>

To workaround this, I have to replace DirectoryIndex:

    DirectoryIndex index.en.html


This breaks multviews on the index page of course, but I have no other way.

Thanks for hints and advices in advance!

Best regards
Zhang Weiwu

-- 
我的博客:
http://zhangweiwu.ixiezi.com/
网站进化论 --写给需要网站或后悔有了网站的人


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] multiviews doesn't work on index pages (and DirectoryIndex properly configured)

Posted by Matus UHLAR - fantomas <uh...@fantomas.sk>.
On 09.03.11 11:29, Zhang Weiwu, Beijing wrote:
> Hello. Debian 5.0, apache 2 2.2.9-10. I've optioned multiviews, and it
> works perfectly fine for every document except index page.
[...]
> 	<Directory /var/www/www.realss.com.cn/htdocs/>
> 		Options FollowSymLinks MultiViews +Includes
> 		DirectoryIndex index
> 		AllowOverride All
> 		Order allow,deny
> 		allow from all
> 		AddHandler server-parsed .shtml
> 		SSITimeFormat "%S"
> 		XBitHack on
> 		Header append Vary cookie 
> 	</Directory>

Have you tried using LanguagePriority and ForceLanguagePriority?

-- 
Matus UHLAR - fantomas, uhlar@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org