Post by ketsap » Sat Oct 13, 2018 9:56 pm

Hi I work with opencart 3.1 and my final goal is to redirect all non-www urls to www url. First I read that I can do this from .htaccess file. So because it wasn't to my directory /public_html I took the htacceess.txt and pasted it from opencart repo to my directory ( /public_html ) and rename it .htaccess. Inside I read that I should enable mod_rewrite to the apache server. The problem is that I can't find where I can change that.Is it enable the mod_rewrite by default?
Also now that I have move the htaccess file I get a 500 error.

Final inside the htaccess file it has this line of code
# If your opencart installation does not run on the main web folder make sure you folder it does run in
ie. / becomes /shop/

I can not understand that it is doing. should I change it to something else?
Thank you George.

Newbie

Posts

Joined
Sat Oct 13, 2018 9:41 pm

Post by IP_CAM » Sun Oct 14, 2018 9:42 pm

# If your opencart installation does not run on the main web folder, make sure you folder it does run in
ie. / becomes /shop/

Code: Select all

# SEO URL Settings
RewriteEngine On
# If your opencart installation does not run on the main web folder,
# but in a Subdirectory /cart/, make sure your folder / becomes /cart/
RewriteBase /cart/

Code: Select all

# SEO URL Settings
RewriteEngine On
# If your opencart installation does not run on the main web folder,
# but in a Subdirectory /shop/, make sure your folder / becomes /shop/
RewriteBase /shop/

Code: Select all

# SEO URL Settings
RewriteEngine On
# If your opencart installation does run on the main web folder,
# make sure you folder does run in:
RewriteBase /
understud ? :D
Ernie

Please don't send me OC Forum Personal Messages, just contact: jti@jacob.ch
---
OC 1.5.6.5 LIGHT Test Site: http://www.bigmax.ch/shop/
OC 1.5.6.5 V-PRO Test Site: http://www.jacob.ch/shop/
My Github OC Site: https://github.com/IP-CAM
2'250+ FREE OC Extensions from the World's largest Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland
Who is online

Users browsing this forum: purpletreesoft and 22 guests