tags:

views:

61

answers:

1
  • /index/ to /index.php

  • /index/hello to /index.php/hello

The site is use path_info, and the default rule not works:

RewriteRule ^([^/]+)/(.*)$      $1.php/$2   [L]

I change to:

RewriteRule ^([^/.]+)((/[^/]+)*)/?$ $1.php$2 [L]

That was strange

  • */index/ to /index.php works fine

  • /index/hello to /index.php/hello not work

And it says No input file specified.

Php is run in fast cgi mode in Apache.

A: 

path_info differs on every server and combination of Webserver and PHP. Why not use GET variables to do the routing?

RewriteRule ^([^/.]+)((/[^/]+)*)/?$ routing.php/?site=$1&module=$2 [L]
DrDol
Thank you,I finish that by using a routing php file
ni