Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8598735
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T01:13:31+00:00 2026-06-12T01:13:31+00:00

I want to create a rewrite rule so that www.example.com/whatever/here Would map to www.example.com/index.php/whatever/here

  • 0

I want to create a rewrite rule so that

www.example.com/whatever/here

Would map to

www.example.com/index.php/whatever/here

So that $_SERVER['PATH_INFO'] is available. For that, I have created the following ruleset:

RewriteEngine On
RewriteCond {%REQUEST_FILENAME} !-f
RewriteCond {%REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1

Only this gives me a 500 server error. The Apache error log states that

[Sun Sep 30 17:23:08.758705 2012] [core:error] [pid 2584:tid 1704]
[client ::1:58591] AH00124: Request exceeded the limit of 10 internal
redirects due to probable configuration error. Use
‘LimitInternalRecursion’ to increase the limit if necessary. Use
‘LogLevel debug’ to get a backtrace.

But I fail to see the recursion. When I try it with, let’s say a query:

RewriteRule ^(.*)$ index.php?route=$1

It works as expected, but $_SERVER['PATH_INFO'] is not available.


Also, before anyone asks, I want $_SERVER['PATH_INFO'] because that way, I can have complicated paths like so:

www.example.com/controller/action/data?more=data

if I require it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T01:13:33+00:00Added an answer on June 12, 2026 at 1:13 am

    Your server environment variables are specified incorrectly in the RewriteCond, if that is your real code. If not a flat out 500 parse error, this would cause the conditions to be ignored and the rewrite to take place on every request causing a loop.

    RewriteEngine On
    # The % goes outside the {}
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    # And add a [L] flag
    RewriteRule ^(.*)$ index.php/$1 [L]
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How would you create a regular expression that would parse the following url http://example.com/answers/38-my-example-question-on-regular-expression
I have this link http://xxxx.com/yyyy/index.php?class=Applications&function=create and I want to make it look like this
I want to create URL re-write rules for following URL in htaccess. http://example.com/vedios/category/fun/ ->
I want to create an asp.net white-label site http://whitelabel.com , that could be styled
Need Help, I want create an image access caching, example image at url example.com/caching/m_images.jpg
I want create wordpress website into which I want create user management... That means
i want create a custom json data from the mssql 2008 results so that
I want to create a new field (or two) in my table that is
How to create a 301 redirect in IIS7 using the Rewrite Rule extension for
I am looking to create a few rewrite rules. Here are the types of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.