Post by adriankoooo » Thu Mar 03, 2011 8:05 pm

Hi!

I am trying to enable SEO friendly URL's, I have enabled this function in settings.

.htaccess looks like this:

Code: Select all

### autogenerated - do not edit between these lines
AuthName "restricted access"
AuthType Basic
AuthUserFile /home/html/mihalko.eu/public_html//.users

require valid-user
### autogenerated - do not edit between these lines


# 1.To use URL Alias you need to be running apache with mod_rewrite enabled. 

# 2. In your opencart directory rename htaccess.txt to .htaccess

# For any support issues please visit: http://www.opencart.com

Options +FollowSymlinks

# Prevent Directoy listing 
Options -Indexes

# Prevent Direct Access to files
<FilesMatch "\.(tpl|ini)">
 Order deny,allow
 Deny from all
</FilesMatch>

# SEO URL Settings
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]


### Additional Settings that may need to be enabled for some servers 
### Uncomment the commands by removing the # sign in front of it.
### If you get an "Internal Server Error 500" after enabling, then restore the # as this means your host doesn't allow that.

# 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it:
#php_flag register_globals off
http://d.pr/eKa2+

Active Member

Posts

Joined
Thu Mar 03, 2011 6:52 am


Post by adriankoooo » Thu Mar 03, 2011 9:35 pm

# Prevent Directoy listing
Options +FollowSymlinks
Options -Indexes

Without this 2 line it is OK, why?

Active Member

Posts

Joined
Thu Mar 03, 2011 6:52 am


Post by Xsecrets » Thu Mar 03, 2011 9:57 pm

some server setups just don't like those lines, and some won't work without them.

OpenCart commercial mods and development http://spotonsolutions.net
Layered Navigation
Shipment Tracking
Vehicle Year/Make/Model Filter


Guru Member

Posts

Joined
Sun Oct 25, 2009 3:51 am
Location - FL US

Post by Dunald » Sat Mar 19, 2011 3:03 am

When I rename htaccess.txt to .htaccess
I also get " 500 internal server error"
What can I do to repair this. I have my server at one.com and they say that apache with mod_rewrite is enabled.
I also tried to uncomment the commands by removing the # at the lines:
# Prevent Directoy listing
Options +FollowSymlinks
Options -Indexes
But the problem is the same!

What can I do. I need my store to be SEO friendly.

Active Member

Posts

Joined
Tue Mar 15, 2011 9:05 pm

Post by lapservice » Thu Jul 21, 2011 3:52 pm

Remove this line:
Options +FollowSymlinks
or rename to :
Options +SymLinksIfOwnerMatch

Newbie

Posts

Joined
Thu Jul 21, 2011 3:49 pm

Post by welfordmedia » Thu Jul 21, 2011 6:10 pm

Dunald wrote:When I rename htaccess.txt to .htaccess
I also get " 500 internal server error"
What can I do to repair this. I have my server at one.com and they say that apache with mod_rewrite is enabled.
I also tried to uncomment the commands by removing the # at the lines:
# Prevent Directoy listing
Options +FollowSymlinks
Options -Indexes
But the problem is the same!

What can I do. I need my store to be SEO friendly.
500 errors are really unhelpful from servers, but if you check your server logs then you may find the answer as they usually say what caused it.

It could also be the way the server is configured, if its plesk then you have multiple options to run php as an apache module, fast cgi or cgi (apache module is fine for me) - also try turning php safe mode off too.

An awesome Web Development company based in Leeds. E-Commerce Specialists by day, Geeks and Gamers by night

Tel: 0845 634 1838
Web: http://www.welfordmedia.co.uk
Twitter: https://twitter.com/welfordmedia
Facebook: https://www.facebook.com/welfordmedia


User avatar
Active Member

Posts

Joined
Thu Jul 21, 2011 5:59 pm
Location - Leeds, UK

Post by johans » Thu Nov 10, 2011 4:47 pm

i have also same problem as this.

i tried this..... Options +FollowSymlinks to Options +SymLinksIfOwnerMatch

still not working 500 internal error. I have read many solutions but its not working with me.

Any suggestions to make this work?

Thanks,
Mr. J


New member

Posts

Joined
Mon Oct 17, 2011 5:08 pm

Post by johans » Thu Nov 10, 2011 5:33 pm

my .htaccess is this.

# 1.To use URL Alias you need to be running apache with mod_rewrite enabled.

# 2. In your opencart directory rename htaccess.txt to .htaccess.

# For any support issues please visit: http://www.opencart.com



# Prevent Directoy listing


# Prevent Direct Access to files
<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>

# SEO URL Settings
RewriteEngine On
# If your opencart installation does not run on the main web folder make sure you folder it does run in ie. / becomes /shop/

RewriteBase /
RewriteRule sitemap.xml /index.php?route=feed/google_sitemap
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]

### Additional Settings that may need to be enabled for some servers
### Uncomment the commands by removing the # sign in front of it.
### If you get an "Internal Server Error 500" after enabling any of the following settings, restore the # as this means your host doesn't allow that.

# 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it:
# php_flag register_globals off

# 2. If your cart has magic quotes enabled, This may work to disable it:
# php_flag magic_quotes_gpc Off

# 3. Set max upload file size. Most hosts will limit this and not allow it to be overridden but you can try
# php_value upload_max_filesize 999M

# 4. set max post size. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value post_max_size 999M

# 5. set max time script can take. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_execution_time 200

# 6. set max time for input to be recieved. Uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_input_time 200

Thanks,
Mr. J


New member

Posts

Joined
Mon Oct 17, 2011 5:08 pm

Post by wir.org » Sat Mar 22, 2014 6:23 pm

johans wrote:my .htaccess is this.

# 1.To use URL Alias you need to be running apache with mod_rewrite enabled.

# 2. In your opencart directory rename htaccess.txt to .htaccess.

# For any support issues please visit: http://www.opencart.com



# Prevent Directoy listing


# Prevent Direct Access to files
<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>

# SEO URL Settings
RewriteEngine On
# If your opencart installation does not run on the main web folder make sure you folder it does run in ie. / becomes /shop/

RewriteBase /
RewriteRule sitemap.xml /index.php?route=feed/google_sitemap
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]

### Additional Settings that may need to be enabled for some servers
### Uncomment the commands by removing the # sign in front of it.
### If you get an "Internal Server Error 500" after enabling any of the following settings, restore the # as this means your host doesn't allow that.

# 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it:
# php_flag register_globals off

# 2. If your cart has magic quotes enabled, This may work to disable it:
# php_flag magic_quotes_gpc Off

# 3. Set max upload file size. Most hosts will limit this and not allow it to be overridden but you can try
# php_value upload_max_filesize 999M

# 4. set max post size. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value post_max_size 999M

# 5. set max time script can take. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_execution_time 200

# 6. set max time for input to be recieved. Uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_input_time 200
IT WORKS! Thanks!

Newbie

Posts

Joined
Sun Mar 09, 2014 7:03 pm

Post by zinaf » Thu Jun 05, 2014 1:40 am

I had the same problem on Opencart 1.5.6.3
as my site was not installed on my domainname.com but on shop.domainname.com I changed the .htaccess to

Code: Select all

RewriteBase /shop/
However when I changed it back to

Code: Select all

RewriteBase /
it all worked perfectly fine.
It may be something specific to my host provider but it resolved my problem.
cheers

Newbie

Posts

Joined
Wed Jul 31, 2013 4:01 am

Post by faisalturk » Sun Aug 17, 2014 4:24 am

zinaf wrote:I had the same problem on Opencart 1.5.6.3
as my site was not installed on my domainname.com but on shop.domainname.com I changed the .htaccess to

Code: Select all

RewriteBase /shop/
However when I changed it back to

Code: Select all

RewriteBase /
it all worked perfectly fine.
It may be something specific to my host provider but it resolved my problem.
cheers
Same Here: I use Godaddy Hosting and try many options. Then I just left it

Code: Select all

RewriteBase /
and working fine.

Newbie

Posts

Joined
Thu Jul 24, 2014 3:23 pm

Post by hslee5 » Wed Dec 31, 2014 12:36 pm

johans wrote:my .htaccess is this.

# 1.To use URL Alias you need to be running apache with mod_rewrite enabled.

# 2. In your opencart directory rename htaccess.txt to .htaccess.

# For any support issues please visit: http://www.opencart.com



# Prevent Directoy listing


# Prevent Direct Access to files
<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>

# SEO URL Settings
RewriteEngine On
# If your opencart installation does not run on the main web folder make sure you folder it does run in ie. / becomes /shop/

RewriteBase /
RewriteRule sitemap.xml /index.php?route=feed/google_sitemap
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]

### Additional Settings that may need to be enabled for some servers
### Uncomment the commands by removing the # sign in front of it.
### If you get an "Internal Server Error 500" after enabling any of the following settings, restore the # as this means your host doesn't allow that.

# 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it:
# php_flag register_globals off

# 2. If your cart has magic quotes enabled, This may work to disable it:
# php_flag magic_quotes_gpc Off

# 3. Set max upload file size. Most hosts will limit this and not allow it to be overridden but you can try
# php_value upload_max_filesize 999M

# 4. set max post size. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value post_max_size 999M

# 5. set max time script can take. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_execution_time 200

# 6. set max time for input to be recieved. Uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_input_time 200
WOW!!! I've been looking for solution for 3 days. Copy and edit this code to my .htaccess file work fine for me now. TQ Johans

Newbie

Posts

Joined
Tue Dec 30, 2014 5:38 pm

Post by sureshking » Tue Jun 21, 2016 6:09 pm

Dear friends,
i have a problem with seo url.i got 404 not found error.
1.i changed .htaccess.txt to .htaccess
2.change the settings seo url on.
3.i give seo keywords for allcategories but still problem

below the ht access code
# 1.To use URL Alias you need to be running apache with mod_rewrite enabled.

# 2. In your opencart directory rename htaccess.txt to .htaccess.

# For any support issues please visit: http://www.opencart.com

Options +FollowSymlinks

# Prevent Directoy listing
Options -Indexes

# Prevent Direct Access to files
<FilesMatch "(?i)((\.tpl|\.ini|\.log|(?<!robots)\.txt))">
Order deny,allow
Deny from all
</FilesMatch>

# SEO URL Settings


RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)\?*$ index.php?_route_=$1 [L,QSA]

### Additional Settings that may need to be enabled for some servers
### Uncomment the commands by removing the # sign in front of it.
### If you get an "Internal Server Error 500" after enabling any of the following settings, restore the # as this means your host doesn't allow that.

# 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it:
# php_flag register_globals off

# 2. If your cart has magic quotes enabled, This may work to disable it:
# php_flag magic_quotes_gpc Off

# 3. Set max upload file size. Most hosts will limit this and not allow it to be overridden but you can try
# php_value upload_max_filesize 999M

# 4. set max post size. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value post_max_size 999M

# 5. set max time script can take. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_execution_time 200

# 6. set max time for input to be recieved. Uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields
# php_value max_input_time 200

# 7. disable open_basedir limitations
# php_admin_value open_basedir none

Newbie

Posts

Joined
Sat May 09, 2015 2:22 am
Who is online

Users browsing this forum: No registered users and 73 guests