Rewrite 404s

Status
Not open for further replies.

marvso

Member
Messages
61
Reaction score
0
Points
6
Sorry if there is already a topic about this...
I have a very simple php-run CMS that uses the mod rewrite function. And, like everyone else, I'm having trouble accessing the pages under their rewritten urls (404 errors).

I've set my permissions to 755 (they were even originally lower) and replaced my .htaccess with the original file, which reads:
Code:
# -FrontPage-

IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName mariovsonic.pcriot.com
AuthUserFile /home/marvso/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/marvso/public_html/_vti_pvt/service.grp
ErrorDocument 404 /notfound.html 
Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*)\.htm$ index.php?page=$1

But the problem still persists. Has anyone found a working solution?
 

callumacrae

not alex mac
Community Support
Messages
5,257
Reaction score
97
Points
48
Won't that tell notfound.html to point to index.php?page=notfound?

In my experience with mod_rewrite, it messes stuff up more than it makes stuff look good.

~Callum
 

dlukin

New Member
Messages
427
Reaction score
25
Points
0
Seems to work for me:

Uh-oh! Something went wrong and now you're lost! This means that
either:

A) You clicked on a broken link (click here to report it)

B) You wanted to see this nice 404 error page or

C) You need to practice your typing.

What now?
 

Livewire

Abuse Compliance Officer
Staff member
Messages
18,169
Reaction score
216
Points
63
I'm gunna bet ErrorDocument takes priority over the rewrite rule, or otherwise Alex would've been right and it'd rewrite the error. In any case as long as it works, that's what matters :)
 
Last edited:

Livewire

Abuse Compliance Officer
Staff member
Messages
18,169
Reaction score
216
Points
63
I didn't even see the missing L in the filter >_<
 
Status
Not open for further replies.
Top