Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

frutal attempts to remove OscId from url


PHP_User

Recommended Posts

I am creating a new store on our site and its one level down (for now) from our current store. The current store is on the root /store/ and the new store is /xxx2013/store. I cannot seem to get the site to work because its using the oscid on some pages. The current store does not use the get variable, it uses cookies (set in the config).

 

I tried setting the /includes/configure.php with the same settings as the current store, except adding in the path for the lower directory (www.mysite.com/xxx2013).

 

Here is the configure.php settings:

 

 

define('HTTP_SERVER', 'http://www.mysite.net');

define('HTTPS_SERVER', 'http://www.mysite.net');

define('ENABLE_SSL', false);

define('HTTP_COOKIE_DOMAIN', 'www.mysite.net');

define('HTTPS_COOKIE_DOMAIN', 'www.mysite.net');

define('HTTP_COOKIE_PATH', '/xxx2013/store/');

define('HTTPS_COOKIE_PATH', '/xxx2013/store/');

define('DIR_WS_HTTP_CATALOG', '/xxx2013/store/');

define('DIR_WS_HTTPS_CATALOG', '/xxx2013/store/');

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_FS_INCLUDES', '/home3/mysite/public_html/xxx2013/store/includes/'); // absolute path required

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_ADMIN', '/ftcn2013/store/admin/'); // absolute path required

define('DIR_FS_ADMIN', '/home3/freetoc2/public_html/mysitestore/admin/'); // absolute path required

 

define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/home3/mysite/public_html/xxx2013/store/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

define('DB_SERVER', 'localhost');

define('DB_SERVER_USERNAME', 'username');

define('DB_SERVER_PASSWORD', 'password');

define('DB_DATABASE', 'dbname_osc');

define('USE_PCONNECT', 'false');

define('STORE_SESSIONS', 'mysql');

 

 

I appreciate any help.

 

Thanks

Don

Link to comment
Share on other sites

I read through this thread and see several people who seem like their scenario is the same as mine (move catalog from site.com/catalog to site.com/catalog/newsite). But, I do not see an explanation that seemed to correct the OscId url issue.

Link to comment
Share on other sites

@@php_User

 

Don, here is a thread that discusses the oscid topic pretty well. You'll see therein some debate going back and forth but if you digest the gist of it you'll see what's going on including some comments how how to correct oscid issues.

 

I'm not an expert, but what I came up with after sorting through all this is that visitors will get the oscid on their first page view on my sites, but any subsequent navigation (click) the oscid disappears from view. As you'll see in the discussion, this is how it 'should be'.

 

Good luck

I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.

I remember what it was like when I first started with osC. It can be overwhelming.

However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.

There are several good pros here on osCommerce. Look around, you'll figure out who they are.

Link to comment
Share on other sites

I read through this thread and see several people who seem like their scenario is the same as mine (move catalog from site.com/catalog to site.com/catalog/newsite). But, I do not see an explanation that seemed to correct the OscId url issue.

There's no reason to address it directly. Fix the configure file and it will go away. The session ID will usually show with the first click but should go away after that. But only if you setup the configure file correctly, which you haven't done with yours.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Thanks for the insight. What is and is not happening is on the old catalog (mysite.com/store) it never uses the oscid in the url, and it works correctly (when you add an item to the cart and then click of any link on the site, then click on the cart link, the item is still there).

 

On the site I am building (mysite.com/tempdirname/store), the 1st click does not have the id in the url. Then next link you click on, it does. Then if you click on the cart link, the id is gone and so is the item in the cart. Note, both of these sites are using the same database (and only I can access it so I know that there will not be items purchased from this new cart).

 

I took the working sites configure.php file, copiedit to the new store includes, and added /tempdirname/ before the lines that had /store/.

 

As you are suggesting, I will read through the suggested link articles.

 

thanks

Link to comment
Share on other sites

Consider this line in your configure file in which you use the username

define('HTTP_COOKIE_PATH', '/xxx2013/store/');

Then look at the example on the page I sent. Do you see the username used there? Whether or not the configure file is causing the problem, it needs to be fixed or you are just asking for problems.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I don't understand which is the correct config setting. I see several examples and don't know which is correct.

 

define('HTTP_COOKIE_PATH', '/oscommerce1/');

define('HTTP_COOKIE_PATH', '/www.zzzzz.com/catalog/');

define('HTTP_COOKIE_PATH', '/');

 

I saw a post talking about SSL set to true to solve this, so I tried that and it works.

 

But, I want to fix the issue you pointed out.

 

Thanks,

Don

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...