I tried doing a 301 redirect to help my pagerank, but when I did that, I wouldn't be able to login to my admin panel or the site! I'm not sure what the problem is..
I tried doing a 301 redirect to help my pagerank, but when I did that, I wouldn't be able to login to my admin panel or the site! I'm not sure what the problem is..
I was trying to redirect myshop.com to www.myshop.com in my .htaccess file
after this, I wasn't able to login to the admin panel or as a customer. Then I turned it off, and the problem went away. What gives?
any ideas?
Perhaps you need to study more about writing .htaccess rules to ensure what you're using is correct.
I suspect you're getting no feedback due to lack of detail about what you've done and why.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Well I used this code in my .htaccess file:
from here:Code:Options +FollowSymlinks RewriteEngine on rewritecond %{http_host} ^domain.com [nc] rewriterule ^(.*)$ http://www.domain.com/$1 [r=301,nc]
http://www.webconfs.com/how-to-redirect-a-webpage.php
I tried that, and the redirection worked. But I couldn't login to the admin panel or as a customer on the site after the redirection was added.
Interestingly, almost the same code posted here seems to work fine:
http://www.zen-cart.com/forum/showth...248#post447248
Have you tried ensuring that the case-sensitivity isn't an issue?Code:## the following adds the www if it's missing: RewriteEngine On RewriteCond %{HTTP_HOST} ^the_name_of_your_domain.com$ [NC] RewriteRule ^(.*)$ http://www.the_name_of_your_domain.com/$1 [R=301,L]
Also, what errors were appearing in your apache error_log after making the change? Usually the error messages will give you clues to what's wrong.
Also, what's in your configure.php files, namely the first half which talks about the HTTP_xxxxxxx and DIR_WS_xxxxxx settings?
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
in admin/includes/configure.php:
in /includes/configure.php:Code:define('HTTP_SERVER', 'http://www.wishgiving.com'); define('HTTPS_SERVER', 'https://www.wishgiving.com'); define('HTTP_CATALOG_SERVER', 'http://www.wishgiving.com'); define('HTTPS_CATALOG_SERVER', 'https://www.wishgiving.com'); // Use secure webserver for catalog module and/or admin areas? define('ENABLE_SSL_CATALOG', 'false'); define('ENABLE_SSL_ADMIN', 'false'); // NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes! // * DIR_WS_* = Webserver directories (virtual/URL) // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder) define('DIR_WS_ADMIN', '/shop/admin/'); define('DIR_WS_CATALOG', '/shop/'); define('DIR_WS_HTTPS_ADMIN', '/shop/admin/'); define('DIR_WS_HTTPS_CATALOG', '/shop/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_CATALOG_IMAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'images/'); define('DIR_WS_CATALOG_TEMPLATE', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/templates/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_CATALOG_LANGUAGES', HTTP_CATALOG_SERVER . DIR_WS_CATALOG . 'includes/languages/');
Code:define('HTTP_SERVER', 'http://www.wishgiving.com'); define('HTTPS_SERVER', 'https://www.wishgiving.com'); // Use secure webserver for checkout procedure? define('ENABLE_SSL', 'true'); // NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes! // * DIR_WS_* = Webserver directories (virtual/URL) // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder) define('DIR_WS_CATALOG', '/shop/'); define('DIR_WS_HTTPS_CATALOG', '/shop/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', DIR_WS_CATALOG . 'pub/'); define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/'); define('DIR_WS_PHPBB', '/'); // * DIR_FS_* = Filesystem directories (local/physical) //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/ define('DIR_FS_CATALOG', '/home/wishgivi/public_html/shop/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/');
okay ... how about the server error log?
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
I see some serious problems here.
In your config files, you cannot have one that uses 'HTTPS = true' and the other config file using 'HTTPS = false'.
http://www.wishgiving.com/shop/admin/ <<< where are the 'index.php' and '.htaccess' files?
The 'shop/admin/htacces.php' file is a serious security breach. You should use it (for whatever it is there for) then remove it.
Hey rob,
actually you can run ssl true in the cart and ssl false in the admin,
Bookmarks