Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Installation on server101 hosting


Guest

Recommended Posts

Hi I am a newbie when it comes to php and mysql.

I am trying to setup oscommerce, on a shared host at server101.com for testing.

 

I downloaded the files, uploaded the catalog file and started the install from my browser. I had to modify the php files by replacing all instances of $PHP_SELF with $SCRIPT_NAME (fix as found in one of the posts here) as the install would freeze part way throught the first screen.

 

After this fix during install, I have managed to communicate with an empty database I had created but when I try to import the tables and sample data it can't find the oscommerce.sql file.

 

This is the location it is showing.

 

The file to import must be located and named at:

/s101/install/oscommerce.sql

 

I find this puzzling as the file is located within the "catalog" folder as supplied by oscommerce and should read

/catalog/install/oscommerce.sql

 

I don't know where it got the /s101 path, as this does not exist within my hosted space.

 

 

Can anyone shed some light on this problem

 

Thanks

 

Alan

Link to comment
Share on other sites

It is quite possible that your hosting company is locating all sql databases on a seperate server - which is a good thing. If this is the case then you will have to import the data in the oscommerce.sql file via phpMyAdmin.

 

You should have access to this via your web hosting control panel, but if you don't then your hosting company will have to do the import for you.

 

Vger

Link to comment
Share on other sites

I had already looked at myphpadmin but could not see any option for importing data only for exporting tables and data. I'll talk to my hosts today and see if they can help.

 

Thanks

 

Alan

 

It is quite possible that your hosting company is locating all sql databases on a seperate server - which is a good thing.  If this is the case then you will have to import the data in the oscommerce.sql file via phpMyAdmin.

 

You should have access to this via your web hosting control panel, but if you don't then your hosting company will have to do the import for you.

 

Vger

Link to comment
Share on other sites

Hi all,

 

just posting an update.

 

I have resolved the problems with my hosts at server101.com, they have been very helpful by sending instructions on modifying some of the installation files. After applying their changes the installation and configuration completed succesfully.

I can now browse the sight and sample products, but still need to work out a "can not resolve link" problem at the bottom of pages (I think I saw the same problem in another thread).

 

Here are the changes sent to me. These enabled me to complete the installation. I don't know if they are only specific to server101.com installations or if they can be applied to other hosts.

+++++++++++++++++++++++++++++++++++++++++++++++

here are the changes we recommend to get oscommerce working.

please note lines starting with the minus sign are the lines to remove and

lines with the plus sign are the additions.

 

---------------

install/templates/pages/install_2.php

line 78

 

$script_filename = getenv('PATH_TRANSLATED');

- if (empty($script_filename)) {

+ //if (empty($script_filename)) {

$script_filename = getenv('SCRIPT_FILENAME');

- }

+ //}

 

 

install/templates/pages/install_3.php

line 14

 

$script_filename = getenv('PATH_TRANSLATED');

- if (empty($script_filename)) {

+ //if (empty($script_filename)) {

$script_filename = getenv('SCRIPT_FILENAME');

- }

+ //}

 

chmod 400 includes/configure.php

(the chmod needs to be changed after installation has completed for security)

 

includes/configure.php

line 11

+ $PHP_SELF = $_SERVER['SCRIPT_NAME'];

 

 

admin/includes/application_top.php

line 35

for some reason, this line does not work :

$PHP_SELF = (isset($HTTP_SERVER_VARS['PHP_SELF']) ?$HTTP_SERVER_VARS['PHP_SELF']

: $HTTP_SERVER_VARS['SCRIPT_NAME']);

 

it needs to check if it is empty :

$PHP_SELF = (!empty($HTTP_SERVER_VARS['PHP_SELF']) ?

$HTTP_SERVER_VARS['PHP_SELF'] : $HTTP_SERVER_VARS['SCRIPT_NAME']);

------------------------

 

Thanks for your suggestions

Link to comment
Share on other sites

  • 2 months later...

I thought that it might be useful to format the information for Server101 customers, to make the changes easier. I've also added in some hints. Thanks to Martial and Duncan.

 

Server101 Modifications - oscommerce-2.2ms2

 

Minus sign are the lines to remove and

lines with the plus sign are the additions.

Don't include the "+" or "-" into the code.

 

-----------------------------------------

 

install/templates/pages/install_2.php

line 78

 

$script_filename = getenv('PATH_TRANSLATED');

- if (empty($script_filename)) {

+ //if (empty($script_filename)) {

$script_filename = getenv('SCRIPT_FILENAME');

- }

+ //}

-------------------------------------------

 

install/templates/pages/install_3.php

line 14

 

$script_filename = getenv('PATH_TRANSLATED');

- if (empty($script_filename)) {

+ //if (empty($script_filename)) {

$script_filename = getenv('SCRIPT_FILENAME');

- }

+ //}

---------------------------------------------

 

admin/includes/application_top.php

line 35

 

- $PHP_SELF = (isset($HTTP_SERVER_VARS['PHP_SELF']) ? $HTTP_SERVER_VARS['PHP_SELF'] : $HTTP_SERVER_VARS['SCRIPT_NAME']);

+ $PHP_SELF = (!empty($HTTP_SERVER_VARS['PHP_SELF']) ? $HTTP_SERVER_VARS['PHP_SELF'] : $HTTP_SERVER_VARS['SCRIPT_URL']);

 

 

---------------------------------------------

 

Final steps

(After installation and configuration).

Download the file from your site, edit it and then upload it.

Don't mistakenly edit /admin/includes/configure.php!

 

includes/configure.php

Add this to the top of the declarations. Make sure that it isn't commented.

 

+ $PHP_SELF = $_SERVER['SCRIPT_URL'];

 

----------------------------------------------

 

CHMOD 400 includes/configure.php

and also delete the entire /install folder

 

----------------------------------------------

 

Hope this helps,

Sean

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 months later...

Hi I am a beginner and have been following your advice for trying to configure this on Server101. It all seems to go well until the very end when I get the following errors even though it tells me the installation was successful...

 

PHP Warning: fopen(/includes/configure.php): failed to open stream: No such file or directory in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 209 PHP Warning: fputs(): supplied argument is not a valid stream resource in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 210 PHP Warning: fclose(): supplied argument is not a valid stream resource in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 211 PHP Warning: fopen(/admin/includes/configure.php): failed to open stream: No such file or directory in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 259 PHP Warning: fputs(): supplied argument is not a valid stream resource in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 260 PHP Warning: fclose(): supplied argument is not a valid stream resource in /s101-2/home6/colinsnare/catalog/install/templates/pages/install_7.php on line 261

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...