Jump to content

Mod rewrite


dj

Recommended Posts

Hey

I have searched google, this forum and everything else i could think of but could not find any help on this subject.

I have installed Apache on Windows 2000, using it as a development server.

TI am trying to get a url like www.test.com/user to point to www.test.com/user.php?userid=user

I know that i have to use mod rewrite to do this, so i tried to set it up on my server.

I uncommented the line LoadModule rewrite_module modules/mod_rewrite.so but nothing happens. I get the following error now when i try to view the site.

[quote]
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, dj-05@hotmail.co.uk and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.
[/quote]

The error in the error log says

[quote]
[Wed Aug 02 15:44:45 2006] [error] [client 192.168.1.1] mod_rewrite: maximum number of internal redirects reached. Assuming configuration error. Use 'RewriteOptions MaxRedirects' to increase the limit if neccessary.
[/quote]

How do i fix this?

Thanks
Link to comment
Share on other sites

IDK if you can have '/user/ point to '.php?userid=user" or w/e, I know you can do it the other way around, but I know you have to use 'Rewrite Rule'  I think I know how I can help, look at this:

[code]
RewriteRule ^home$ index.php
[/code]
that does this: www.domain.com/home --->www.domain.com/index.php

it shows inddex.php in the browser window while still showing 'home' in the address bar. hope that helps!
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.