Forum Moderators: phranque

Message Too Old, No Replies

Alias won't work within my httpd.conf

got a 404 error

         

guarriman

12:19 pm on Oct 17, 2007 (gmt 0)

10+ Year Member



Hi.

Using Apache 2.0 on Linux (with 'mod_alias' loaded), I want to set an Alias
/events/ --> /usr/www/example/newweb/modules/events/web/

This is part of my 'httpd.conf':
-----------
<VirtualHost 17.213.***.107:80>
ServerAdmin info@example.com
DocumentRoot /usr/www/example/newweb/web
ServerName newweb.example.com
ServerAlias newweb.example.net newwebexample.foo.com
CBandSpeed 2048 35 40
ScriptAlias /cgi-bin /usr/www/cgi-bin/newweb
php_flag display_errors 0
php_flag display_startup_errors 1
php_admin_value safe_mode_include_dir /usr/www/example/newweb
php_admin_value safe_mode_exec_dir /usr/www/cgi-bin/newweb
ErrorLog /usr/www-logs/newweb-error_log
CustomLog "¦/usr/local/sbin/cronolog /usr/www-logs/newweb-access_log_%m-%y" combined

#Events module
Alias /events/ /usr/www/example/newweb/modules/events/web/
<Directory "/usr/www/example/newweb/modules/events/web">
Options Indexes FollowSymLinks
Order Allow,Deny
Allow from all
AllowOverride all
DirectoryIndex index.php
</Directory>
</VirtualHost>
----------------

But if I access:
http://newweb.example.com/events/
I get a 404 error.

Any similar experience? Thank you very much.

[edited by: jdMorgan at 3:34 pm (utc) on Oct. 17, 2007]
[edit reason] examplified and de-linked [/edit]

jdMorgan

3:37 pm on Oct 17, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



1) Did you restart your server after changing the code?

2) If you requested http://newweb.example.com/events/ it should work. However, if you requested http://newweb.example.com/events (no trailing slash) then it won't work, as described in the Apache mod_proxy documentation.

Jim