Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

shared server, another osc sites categories coming up in my category box


liah

Recommended Posts

Hey Everybody! First off, I want to thank you in advance for any help you may provide! :)

 

I don't know php, I dont know webdesign, so bear with me!

 

Another osc site's categories are coming up in my category box due to a shared server. I called my webhost and they gave me the instructions below, but I don't know how to apply them to osc...

 

It says to specify a path using "sessions save path" function to specify where my sessions are saved. So, my questions:

 

1. How do I access the sessions save path function...is it in the code...? Is it in catalog/admin?

2. What folder should I be saving sessions to?

3. Is this really what I want to do, or is there an easier way to accomplish the goal of not having my categories infiltrated?

 

Thank You!!!

 

Web Host instructions:

 

When using the ?session_start? function in a php script you may get this error:

 

Warning: open(/tmp/php-es/sess_dd2b92bdf6a405f4a63ef5a9e999aded, O_RDWR) failed: No such file or directory (2) in /c3/xeno5993/phpwebsite/open_session.php on line 2

 

This is because you don?t have permissions to the ?/tmp? directory on the server where the php.ini specifies that sessions are stored. However, by using the ?session_save_path? function you can specify where sessions are saved. Specify the path to a folder within your site for sessions to be saved, and override the setting specified in the php.ini. Below is an example:

 

NOTE: It is important that the ?session_save_path? function is called before the ?session_start? function.

 

PHP Session Path Function:

 

Syntax: session_save_path('<absolute_path>');

 

<?php

 

session_save_path("/a1/abcd6789/.sessions");

 

session_start();

 

// create dir

 

 

?>

 

 

Note: You should replace the "/a1/abcd6789" with the home directory for your domain. You can find this information in the Site Information section of your Control Panel.

 

 

home directory: /nfs/cust/x/xx/xx/xxxxx

 

 

 

if the above doesnt work for the save path try this path: /nfs/cust/x/xx/xx/xxxxx/web/ltcp/sessions

Link to comment
Share on other sites

The best thing to do especially when on a shared server is to keep the sessions in the database. Go to your two configure.php files and set sessions to mysql

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

The best thing to do especially when on a shared server is to keep the sessions in the database. Go to your two configure.php files and set sessions to mysql

 

 

Ok, I found the admin/includes/configure, changed that to "mysql"...now I am getting an error message when I try to get to catalog/admin...?

 

Where is the other configure file? I found the admin/configuration, but that doesn't have anything about sessions on it...?

 

Thank you!

Link to comment
Share on other sites

Ok, I found the admin/includes/configure, changed that to "mysql"...now I am getting an error message when I try to get to catalog/admin...?

 

Where is the other configure file? I found the admin/configuration, but that doesn't have anything about sessions on it...?

 

Thank you!

 

 

There are two configure.php files

 

includes/configure.php

admin/includes/configure.php

 

Look for the last line it should look like

 

define('STORE_SESSIONS', 'mysql'); // leave empty '' for default handler or set to 'mysql'

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

There are two configure.php files

 

includes/configure.php

admin/includes/configure.php

 

Look for the last line it should look like

 

define('STORE_SESSIONS', 'mysql'); // leave empty '' for default handler or set to 'mysql'

 

Alright, I found the files! Thank You!

 

New problem:

1. I entered all the database info, username, password, etc. Now my catalog has lost all of the tool bars, images, etc. It is just white with the text, but no formating... ?

 

2. Also, I can get to the first admin page (the big blue box) but then when I click on the links, I get error pages.

 

Thanks ya'll!

Link to comment
Share on other sites

Alright, I found the files! Thank You!

 

New problem:

1. I entered all the database info, username, password, etc. Now my catalog has lost all of the tool bars, images, etc. It is just white with the text, but no formating... ?

 

2. Also, I can get to the first admin page (the big blue box) but then when I click on the links, I get error pages.

 

Thanks ya'll!

 

 

There was no need to change anything but the one line adding mysql.

 

Upload you backup files and one your site is working correctly try changing the line again.

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

There was no need to change anything but the one line adding mysql.

 

Upload you backup files and one your site is working correctly try changing the line again.

 

Thank you so much for your help!

 

Innitially I did just change the mysql line, but then I get the following error on my catalog page:

 

Warning: mysql_connect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /nfs/cust/x/xx/xx/xxxxx/web/catalog/includes/functions/database.php on line 19

Unable to connect to database server!

 

So then I entered all of my mysql data, and the website came up, but without the formatting...?

Any ideas?

 

Thanks again, this forum is great!

Link to comment
Share on other sites

Thank you so much for your help!

 

Innitially I did just change the mysql line, but then I get the following error on my catalog page:

 

Warning: mysql_connect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /nfs/cust/x/xx/xx/xxxxx/web/catalog/includes/functions/database.php on line 19

Unable to connect to database server!

 

So then I entered all of my mysql data, and the website came up, but without the formatting...?

Any ideas?

 

Thanks again, this forum is great!

 

That error means that either the username or password is incorrect. Just changing the sessions line would not give you that error!!!

 

The best thing to do is upload your backup file and start over with the change.

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...