NameSilo

What's wrong with this .htaccess code?

NamecheapNamecheap
Watch
Impact
19
hey
i got this .htaccess file with a script...
Code:
Options +FollowSymlinks
AcceptPathInfo On
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^/]+)/?(.*)      $1.php/$2       [L]
and when i upload it with the script...i get an error:
Code:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, [email protected] 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.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.
Apache/1.3.37 Server at www.mpog.us Port 80
but when i delete the .htaccess file...it works fine...
can anyone help me out with this?
Thanks
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
I think perhaps AcceptPathInfo is not supported by Apache 1.3
 
0
•••
is there a way of going around it? like another command that does the same thing as is supported by APACHE 1.3
 
0
•••
Another question which has happened to me in the past, Is the htaccess file in question definately in the correct directory?
 
0
•••
Are you sure you need it? Have you tried it without it?
 
0
•••
nvm it works when i remove that thing..
 
0
•••
ur welcome! :p
 
0
•••
1 problem tho...i think that line was suppose to change the URLS..because the urls on the website still go .php pages...and in the files...there are no hardcoded urls..so i guess it generates urls using that line of code or something?
 
0
•••
This directive controls whether requests that contain trailing pathname information that follows an actual filename (or non-existent file in an existing directory) will be accepted or rejected. The trailing pathname information can be made available to scripts in the PATH_INFO environment variable.

For example, assume the location /test/ points to a directory that contains only the single file here.html. Then requests for /test/here.html/more and /test/nothere.html/more both collect /more as PATH_INFO.

The three possible arguments for the AcceptPathInfo directive are:

Off
A request will only be accepted if it maps to a literal path that exists. Therefore a request with trailing pathname information after the true filename such as /test/here.html/more in the above example will return a 404 NOT FOUND error.
On
A request will be accepted if a leading path component maps to a file that exists. The above example /test/here.html/more will be accepted if /test/here.html maps to a valid file.
Default
The treatment of requests with trailing pathname information is determined by the handler responsible for the request. The core handler for normal files defaults to rejecting PATH_INFO requests. Handlers that serve scripts, such as cgi-script and isapi-handler, generally accept PATH_INFO by default.

The primary purpose of the AcceptPathInfo directive is to allow you to override the handler's choice of accepting or rejecting PATH_INFO. This override is required, for example, when you use a filter, such as INCLUDES, to generate content based on PATH_INFO. The core handler would usually reject the request, so you can use the following configuration to enable such a script:
http://httpd.apache.org/docs/2.0/mod/core.html
 
0
•••
Dynadot — .com TransferDynadot — .com Transfer

We're social

Spaceship
Domain Recover
CatchDoms
DomainEasy — Zero Commission
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back