Jump to content

Disable Custom 404 or Make it pass along Exact Server Error - PS 1.6.x


protechtrader

Recommended Posts

I have a setup in which the host throw 403 forbidden for some files and with Friendly URLs on and the default HTACCESS prestashop displays the internal prestashop 404 page (with htaccess off I see the servers 403 forbidden).  I need to keep my htaccess in place for this site for now as it uses friendly URLs and is a active site, but despite all of my efforts I have not been able to get Presta to show me the real 403 error.

 

I have tried adding many rewrite rules to the beginning of HTaccess to have it not rewrite the modules folder as well as I tried to get prestashop to not process the folder under dispatcher without any luck.   I need to be able to see the servers 403 message for all or specific files, or I need a way to have prestashop show the 403 error message on it's error page or in place of it.  

 

Anyone have any suggestions for me?

 

Thanks!

Link to comment
Share on other sites

Anyone have any thoughts on this?

 

I have tried a few htaccess methods to have the modules folder skip the rewriterules in htaccess such as:

 

#RewriteCond %{REQUEST_URI} ^/modules/.*)$
#RewriteRule (.*) $1 [L]
 
#RewriteCond %{REQUEST_URI} ^/modules/^
#RewriteRule (.*) $1 [L]
 
#RewriteRule ^modules/*/$ - [L,NC]
#RewriteRule ^modules/.*$ - [PT]
 
Even this right before the prestashop rules hoping it would make it not match modules dir and subdirs:
#RewriteCond %{REQUEST_URI} !^/modules/.*)$
 
None of them seemed to have any effect.
 
I also tried to have prestashop not show the custom error page as well as trying to get the page to not be processed through prestas dispatcher by modifying the pagenotfound functions and calls, but nothing has been successful.
 
Anyone familiar with a way I can do this?  Again, I just am looking to allow PHP files in a module sub-directory to show the raw server 403 error message (as I can see when I disable prestashops htaccess) instead of, or in conjunction with preastashops custom 404 error page.
 
Any help would be greatly appreciated.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...