[Zen Cart] Overwriting .htaccess entries
[Zen Cart] Overwriting .htaccess entries
Thank you
Re: [Zen Cart] Overwriting .htaccess entries
Re: [Zen Cart] Overwriting .htaccess entries
I will need to regenerate the .htaccess regularly, however I have about 200 lines of custom .htaccess redirects as well. How can I rewrite to update for your program, yet retain my code on the .htaccess file? If its not possible, is there another solution that you are aware of. For instance, can I have 2 .htaccess type files somehow?
Thank you for your help.
Re: [Zen Cart] Overwriting .htaccess entries
makenoiz wrote:I will need to regenerate the .htaccess regularly
Are you sure? .htaccess file needs to be generated only once during installation.
Re: [Zen Cart] Overwriting .htaccess entries
-
- Follower
- Posts: 98
- Joined: Sun Feb 03, 2008 9:48 pm
- Location: Kennesaw, GA
- Contact:
Re: [Zen Cart] Overwriting .htaccess entries
Code: Select all
#Working around additional parameter - this one can not be unset in some cases by Core
RewriteCond %{QUERY_STRING} ^(.*)&buy=now$
RewriteRule ^index.php$ index.php?%1 [L,R=301]
#Stopping Rewrite for Performance reasons (if you are using custom Rewrite Rules remove this line)
RewriteRule ^.*(\.php[0-9]{0,1}|\.htm|\.xml|\.css|\.js|\.jpg|\.gif|\.png)$ - [L]
Re: [Zen Cart] Overwriting .htaccess entries
-
- Follower
- Posts: 98
- Joined: Sun Feb 03, 2008 9:48 pm
- Location: Kennesaw, GA
- Contact:
Re: [Zen Cart] Overwriting .htaccess entries
~J~ wrote:Every single line in .htaccess file is important. We hardly do not recommend to remove anything.
But can you at least explain what those two lines are there for since you actually suggested removing the second one? We have 2 lines of custom rewrite rules in the .htaccess and I am not sure if that constitute enough reason to remove the one you suggested remove without knowing why they are there.
Thanks!
Re: [Zen Cart] Overwriting .htaccess entries
The seconds RewriteRule is simple rule for stopping Rewrite Engine for request URIs which clearly does not require handling by Rewrite Rules.