Post by duranto2009 » Tue Aug 11, 2015 10:37 pm

Hey Guyz,

Recently I realized my site (www.abcd.com) needs a cookieless domain to serve the static contents. I'm not so expert in these things, so I just searched over the forums & google. Found couple of articles regarding this.

I need a clear instruction to do so in OpenCart.

Here's a problem, everyone is talking about setting up a cookieless subdomain like static.mydomain.com which is perfectly understood. But I don't want to do it with subdomains. I want my cookieless domain like static.efgh.net So I already bought another domain (efgh.net) to configure my cookieless domain.

Please give me some instruction to configure my cookieless domain (root domain not a subdomain)

Thanks in advance.
Last edited by duranto2009 on Thu Oct 29, 2015 8:39 pm, edited 1 time in total.

Regards,
duranto2009
http://www.marketplacebd.com


Newbie

Posts

Joined
Sun Feb 08, 2015 10:46 pm
Location - Dhaka, Bangladesh

Post by straightlight » Thu Aug 13, 2015 8:03 pm

Googled it, took a few minutes: http://www.wesleysmits.com/how-to-set-u ... ss-domain/

Shows each steps on how to set-up a cookieless domain, including .htaccess. However, since this topic has nothing to do with Opencart itself, I would suggest to either contact your host if you're still not sure on how to initiate a cookieless domain after reading these instructions.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by duranto2009 » Sun Aug 16, 2015 2:32 pm

straightlight wrote:Googled it, took a few minutes: http://www.wesleysmits.com/how-to-set-u ... ss-domain/

Shows each steps on how to set-up a cookieless domain, including .htaccess. However, since this topic has nothing to do with Opencart itself, I would suggest to either contact your host if you're still not sure on how to initiate a cookieless domain after reading these instructions.
Hey straightlight!
Thanks for the heads up, man! :)

I already read that article more than 20 times. Everything is good. Now I know the basic of a cookie-less domain. But how to link the cookie-less domain to my opencart 1.5.6.4 shop. I tried to modify the config.php and admin/config.php files to replace the IMAGE_DIRECTORY. But no luck, after replacing the image directory my admin dashboard shows a warning.

Code: Select all

Warning: Image directory /public_html/image/ not writeable!
Warning: Image cache directory /public_html/image/cache/ not writeable!
And the site doesn't shows up any images. When I viewed the page source I found every image src is empty.
My config.php is:

Code: Select all

<?php
error_reporting(0);
ini_set("display_errors", 0);
// HTTP
define('HTTP_SERVER', 'http://beta.marketplacebd.com/');
define('HTTP_IMAGE', 'http://static.mplcbd.net/image/');

// HTTPS
define('HTTPS_SERVER', 'https://beta.marketplacebd.com/');
define('HTTPS_IMAGE', 'https://static.mplcbd.net/image/');

// DIR
define('DIR_APPLICATION', '/home/---------/public_html/beta/catalog/');
define('DIR_SYSTEM', '/home/------/public_html/beta/system/');
define('DIR_DATABASE', '/home/-------/public_html/beta/system/database/');
define('DIR_LANGUAGE', '/home/-------/public_html/beta/catalog/language/');
define('DIR_TEMPLATE', '/home/------/public_html/beta/catalog/view/theme/');
define('DIR_CONFIG', '/home/------/public_html/beta/system/config/');
define('DIR_IMAGE', '/home/######/public_html/image/');
define('DIR_CACHE', '/home/------/public_html/beta/system/cache/');
define('DIR_DOWNLOAD', '/home/--------/public_html/beta/download/');
define('DIR_LOGS', '/home/--------/public_html/beta/system/logs/');
And the admin/config.php is:

Code: Select all

<?php
// HTTP
define('HTTP_SERVER', 'http://beta.marketplacebd.com/admin/');
define('HTTP_CATALOG', 'http://beta.marketplacebd.com/');
define('HTTP_IMAGE', 'http://static.mplcbd.net/');

// HTTPS
define('HTTPS_SERVER', 'http://beta.marketplacebd.com/beta/admin/');
define('HTTPS_CATALOG', 'http://beta.marketplacebd.com/');
define('HTTPS_IMAGE', 'http://static.mplcbd.net/');

// DIR
define('DIR_APPLICATION', '/home/--------/public_html/beta/admin/');
define('DIR_SYSTEM', '/home/--------/public_html/beta/system/');
define('DIR_DATABASE', '/home/--------/public_html/beta/system/database/');
define('DIR_LANGUAGE', '/home/--------/public_html/beta/admin/language/');
define('DIR_TEMPLATE', '/home/--------/public_html/beta/admin/view/template/');
define('DIR_CONFIG', '/home/--------/public_html/beta/system/config/');
define('DIR_IMAGE', '/home/######/public_html/image/');
define('DIR_CACHE', '/home/--------/public_html/beta/system/cache/');
define('DIR_DOWNLOAD', '/home/--------/public_html/beta/download/');
define('DIR_LOGS', '/home/--------/public_html/beta/system/logs/');
define('DIR_CATALOG', '/home/--------/public_html/beta/catalog/');

I don't get it, everything looks just perfect! :( where is the problem ??? what am I missing?? :-[

Regards,
duranto2009
http://www.marketplacebd.com


Newbie

Posts

Joined
Sun Feb 08, 2015 10:46 pm
Location - Dhaka, Bangladesh

Post by straightlight » Sun Aug 16, 2015 6:11 pm

Ensure that your chmod settings are set to the maximum level on these two image folders in recursive mode (777, if fails, 755),

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by IP_CAM » Tue Aug 18, 2015 10:26 am

or then, look here, I tried to make it easy:
http://www.opencart.com/index.php?route ... n_id=23506
Good Luck
Ernie
hitline.info/shop/

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

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

Post by bibiloute » Sat Oct 10, 2015 8:35 pm

hello,

i try many time but when i make performance test it say no cookie less domain...

all my image are not served from subdomain this is work but why it's not cookie less i don't know how to do
i have access to my Htaccess etc..

Newbie

Posts

Joined
Wed Oct 02, 2013 10:45 pm

Post by VictorDrummond » Sat Oct 10, 2015 9:03 pm

In the process of converting my Oc site over to serve all content via https, I discovered that if Opencart served from http://www. it did in fact serve from cookie-less and therefore scored 100/100 on pingdom test (with other relevant .htaccess code caching code that has nothing to do with serving from cookie-less part).

Hosting for Oc 2.x: Well tested on 2.03.1 including emails work correctly, cPanel Shared or WHM VPS, managed security, fast & reliable SSD drives, Raid 10 /4 disk redundancy, server locale - Texas, contact me to discuss further.


User avatar
Active Member

Posts

Joined
Sat Dec 15, 2012 12:41 pm
Location - On the balcony slammin' Margaritas

Post by VictorDrummond » Sat Oct 10, 2015 9:09 pm

duranto2009 wrote: I don't get it, everything looks just perfect! :( where is the problem ??? what am I missing?? :-[
You're serving from http://

Hosting for Oc 2.x: Well tested on 2.03.1 including emails work correctly, cPanel Shared or WHM VPS, managed security, fast & reliable SSD drives, Raid 10 /4 disk redundancy, server locale - Texas, contact me to discuss further.


User avatar
Active Member

Posts

Joined
Sat Dec 15, 2012 12:41 pm
Location - On the balcony slammin' Margaritas

Post by IP_CAM » Sun Oct 11, 2015 1:12 am

bibiloute wrote:i try many time but when i make performance test it say no cookie less domain...
all my image are not served from subdomain this is work
but why it's not cookie less i don't know how to do
i have access to my Htaccess etc..
ANY SITE, containing SOMETHING, related with setting Browser- COOKIES, is called: NO COOKIE LESS DOMAIN.

By example, OC Images may be called from:
http://www.othershop.whatever....
instead of, calling them from:
http://www.myshop.whatever.....

or, like by default, linked 'internally', directly calling them from:
image/data/whatever...
or:
catalog/view/theme/default/image/whatever...
is, strictly Cookie-technically, all the same.

Therefore, IF my shop is configured to work under:
http://www.myshop.whatever......
and the other Shop, where my images are placed, is called under:
http://www.othershop.whatever....

THEN, despite of, this beeing a Remote Image Subdomain Routine, it's still NOT A COOKIE FREE SUBDOMAIN CALL.
...
A simple way of Cookie FREE Image (sub) Domain would/could therefore be:

http://myshop.whatever.....
or:
http://othershop.whatever....

if, under THIS Link-Call, nothing ELSE on the Site, in the Server ROOT Section, creates some Cookies, when such an URL is called, without the USE of the WWW

Ernie
openshop.li/shop/

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

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

Post by saliverdim » Mon Feb 27, 2017 8:44 am

please help me for oc 2 ?

Active Member

Posts

Joined
Wed Oct 07, 2015 12:15 am

Post by saliverdim » Tue Feb 28, 2017 3:56 am

please

Active Member

Posts

Joined
Wed Oct 07, 2015 12:15 am

Post by saliverdim » Tue Mar 28, 2017 1:25 am

waiting help :(

Active Member

Posts

Joined
Wed Oct 07, 2015 12:15 am

Post by IP_CAM » Wed Mar 29, 2017 11:17 am

.... then better use the commercial forum, if you need it, and do not understand, how to make it work.
I do not use anymore v-2's, to make tests.
Ernie

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

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

Post by tomeda » Tue May 09, 2017 11:56 pm

I did successfully migrated all my images to a static domain and my website is working just fine except for file manager in Journal theme menu.

It opens the correct image location, I'm able to upload images, create folders. But when I insert image into post or option the url is from non static domain which causes break of image (404). Does anybody with Journal theme solved that problem. I think it's related to some modification of theme to file manager but still have no success to find out what is it.

https://drive.google.com/file/d/0BzPa5u ... sp=sharing

OpenCart SEO Services
http://tomeda.bg


User avatar
New member

Posts

Joined
Thu Mar 19, 2015 4:48 am

Who is online

Users browsing this forum: No registered users and 2 guests