By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,614 Members | 1,662 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,614 IT Pros & Developers. It's quick & easy.

mod_rewrite and /

P: n/a
When you type in a url without a filename, e.g. www.google.com/, it
automatically looks for index.php (or whatever your web server is
configured to look for). I am having the problem where my CMS is
returning a page not found in this case.

Try typing in http://www.quick2m.com/izzy -- you get 404
Try typing in http://www.quick2m.com/izzy/index.php -- you get the
homepage

Is this something I can fix with mod_rewrite? How would I write a rule
that looks for a blank URL line and replaces it with index.php?

thanks,
Kevin
Feb 20 '08 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Kevin Audleman schrieb:
When you type in a url without a filename, e.g. www.google.com/, it
automatically looks for index.php (or whatever your web server is
configured to look for). I am having the problem where my CMS is
returning a page not found in this case.

Try typing in http://www.quick2m.com/izzy -- you get 404
Try typing in http://www.quick2m.com/izzy/index.php -- you get the
homepage

Is this something I can fix with mod_rewrite? How would I write a rule
that looks for a blank URL line and replaces it with index.php?
No, this shouldn't normally happen.
Check
http://httpd.apache.org/docs/2.2/de/...directoryslash
and Directory-Index-Setting.
Feb 20 '08 #2

P: n/a
Kevin Audleman wrote:
When you type in a url without a filename, e.g. www.google.com/, it
automatically looks for index.php (or whatever your web server is
configured to look for). I am having the problem where my CMS is
returning a page not found in this case.

Try typing in http://www.quick2m.com/izzy -- you get 404
Try typing in http://www.quick2m.com/izzy/index.php -- you get the
homepage

Is this something I can fix with mod_rewrite? How would I write a rule
that looks for a blank URL line and replaces it with index.php?

thanks,
Kevin
alt.apache.configuration would be a much better place to ask this question.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Feb 20 '08 #3

P: n/a
On Feb 20, 7:28*pm, Kevin Audleman <kevin.audle...@gmail.comwrote:
When you type in a url without a filename, e.g.www.google.com/, it
automatically looks for index.php (or whatever your web server is
configured to look for). I am having the problem where my CMS is
returning a page not found in this case.

Try typing inhttp://www.quick2m.com/izzy-- you get 404
Try typing inhttp://www.quick2m.com/izzy/index.php-- you get the
homepage

Is this something I can fix with mod_rewrite? How would I write a rule
that looks for a blank URL line and replaces it with index.php?

thanks,
Kevin
Hi Kevin,

I would suggest checking your apache httpd.conf file.

Look for DirectoryIndex and it should be something like this:

DirectoryIndex index.php index.xml index.html index.htm index.jsp

This should then allow you to find those pages when you just type in
e.g www.google.co.uk

Regards
Alex

Alex Richards
Ajtrichards Web Solutions
http://www.ajtrichards.co.uk
Feb 21 '08 #4

This discussion thread is closed

Replies have been disabled for this discussion.