Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

After uploading to web-hosting


Roman_Pod

Recommended Posts

Posted

I made all the development on local PC with Apache and PHP and everything worked without problems.

 

Yesterday I uploaded shop to web-hosting and made some editions (path) in config.php files.

I can see main page, account data, but I can not go to catalog and products. Server gives 404 error.

 

What could be the possible reason for such behaviour? Thank you in advance!

Posted

I made all the development on local PC with Apache and PHP and everything worked without problems.

 

Yesterday I uploaded shop to web-hosting and made some editions (path) in config.php files.

I can see main page, account data, but I can not go to catalog and products. Server gives 404 error.

 

What could be the possible reason for such behaviour? Thank you in advance!

Did you simply upload your local osC files to a clean hosting account?

 

osC either has to be installed on the host or you have to manually create the database (the database is not stored in the web space) on your new host.

 

Are you sure you no longer have any reference to localhost? Or, if you had your domain pointed to your local pc did you point it to your new host?

 

A 404 is a simple page not found so, the link you clicked last before you got the 404 Error, what is the exact URL?

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Posted

Did you simply upload your local osC files to a clean hosting account?

 

 

Yes, I uploaded them in public_html directory, then edited config.php files with references and paths. Most probably I ahve some errors in these files, I think.

 

 

osC either has to be installed on the host or you have to manually create the database (the database is not stored in the web space) on your new host.

 

 

For sure, I have uploaded dump of my base to the web-server. Before I made it I had been receiving "Database connection error" from server.

 

 

 

Are you sure you no longer have any reference to localhost? Or, if you had your domain pointed to your local pc did you point it to your new host?

 

A 404 is a simple page not found so, the link you clicked last before you got the 404 Error, what is the exact URL?

 

Here are my config.php files, please, check them if possible.

 

Example of url which causes 404 error: url/catalog/linksys-wrt54gl-p-28.html?osCsid=pe0150ia2nn56c90mcp456coc3

 

Include/configure.php

 

<?php

define('HTTP_SERVER', 'http://url');

define('HTTPS_SERVER', 'https://url');

define('ENABLE_SSL', false);

define('HTTP_COOKIE_DOMAIN', 'http://url');

define('HTTPS_COOKIE_DOMAIN', 'https://url');

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

define('HTTPS_COOKIE_PATH', '/catalog/');

define('DIR_WS_HTTP_CATALOG', '/catalog/');

define('DIR_WS_HTTPS_CATALOG', '/catalog/');

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

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

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_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/catalog/');

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', '***');

define('DB_SERVER_PASSWORD', '****');

define('DB_DATABASE', '*****');

define('USE_PCONNECT', 'false');

define('STORE_SESSIONS', 'mysql');

?>

 

Admin/include/configure.php

 

<?php

define('HTTP_SERVER', 'http://url/');

define('HTTP_CATALOG_SERVER', 'http://url/');

define('HTTPS_CATALOG_SERVER', 'http://url/');

define('ENABLE_SSL_CATALOG', 'false');

define('DIR_FS_DOCUMENT_ROOT', '/home/u/unwiremeru/public_html/catalog/');

define('DIR_WS_ADMIN', 'catalog/admin/');

define('DIR_FS_ADMIN', '/home/u/unwiremeru/public_html/catalog/admin/');

define('DIR_WS_CATALOG', 'catalog/');

define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/catalog/');

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

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

define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

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', DIR_WS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');

define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');

define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

 

define('DB_SERVER', 'localhost');

define('DB_SERVER_USERNAME', '****');

define('DB_SERVER_PASSWORD', '****');

define('DB_DATABASE', '****');

define('USE_PCONNECT', 'false');

define('STORE_SESSIONS', 'mysql');

?>

Posted

What url coming for page not found.

 

 

Was seo urls on when you were working offline.

 

Also check server error log for the reason.

 

Specially you need to paste url for which it says page not found.

 

Did you do some hard coding while developing offline or used all oscommerce standards.

 

 

 

Satish

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Posted

What url coming for page not found.

 

 

 

This is url example for catalog

http://url/catalog/software-c-2.html?osCsid=b802c89ut3n9f2td3ldg0it387

 

Was seo urls on when you were working offline.

 

 

Yes, SEO URLs were always on after installation.

 

 

Also check server error log for the reason.

 

 

 

Is it possible to check it via Administration panel? How to check error log?

 

Did you do some hard coding while developing offline or used all oscommerce standards.

 

 

 

No hard coding, only add-ons.

Posted

That is not a valid URL with a FQDN. If you want help you either need to tell us the EXACT, REAL stuff, or start a PM with someone willing to help.

 

 

Edit: After I left I realized, that is the EXACT url that his configure.php file is telling the server to look for.

 

Fix your domain name in your configure.php files.

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Posted

This is url example for catalog

http://url/catalog/s...9f2td3ldg0it387

 

 

 

Yes, SEO URLs were always on after installation.

 

 

 

Is it possible to check it via Administration panel? How to check error log?

 

 

 

 

No hard coding, only add-ons.

 

Are you sure your htaccess has proper rewrite rules and your server supports mod rewrite.

 

Satish

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Posted

What domain name should be in config.php

 

Exact url of shop is http://unwireme.ru.swteh.ru/catalog/

This part of both configure.php files need the domain information in it...

 

<?php
define('HTTP_SERVER', 'http://unwireme.ru.swteh.ru');
define('HTTP_CATALOG_SERVER', 'http://unwireme.ru.swteh.ru');
define('HTTPS_CATALOG_SERVER', 'https://unwireme.ru.swteh.ru');  <--- only needed if using a ssl

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Posted

This part of both configure.php files need the domain information in it...

 

<?php
define('HTTP_SERVER', 'http://unwireme.ru.swteh.ru');
define('HTTP_CATALOG_SERVER', 'http://unwireme.ru.swteh.ru');
define('HTTPS_CATALOG_SERVER', 'https://unwireme.ru.swteh.ru');  <--- only needed if using a ssl

 

It is already there right from the start. I just replaced it here with URL abbreviature.

Posted

First thing you need to do is to secure your site from hackers. If you don't then this will all be wasted.

 

 

I totally agree with you regarding securing my site. But it is the next step in development.

It is test installation on web-hosting, it is not actual shop. Just tried to work in web and has got first problem. Unfortunately it has not solved yet.

 

Then turn off the SEO URL's and get the shop working without that add on first.

 

I tried to turn off the SEO URL and no result. Catalog still is not seen. Could you please specify more what the problem is with SEO URL? COuld it be solved without turning this add-on off?

Posted

seo url contrib (in most versions) cannot be turned off via the admin.

 

double check your ftp if your htaccess file is there, with the correct info for your mod rewrites, and that your server actually allows for mod rewrites. open a ticket with your host if not sure.

 

and as for your config file ... tghe cookie domains should be with the http://, just make them '.domainname.com' for best success in making them work, from my experience.

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Posted

seo url contrib (in most versions) cannot be turned off via the admin.

 

 

Yes, I have managed to turn it off via admin. You can check it on site, now urls in catalog are in standard way like: http://unwireme.ru.swteh.ru/catalog/product_info.php?products_id=28

 

 

 

double check your ftp if your htaccess file is there, with the correct info for your mod rewrites, and that your server actually allows for mod rewrites. open a ticket with your host if not sure.

 

htaccess is there, but which info should be placed in file to allow mod rewrites?

Posted

seo url contrib (in most versions) cannot be turned off via the admin.

 

 

After turning SEO URL off, I have got the following result in browser:

This webpage has a redirect loop.

 

The webpage at http://unwireme.ru.swteh.ru/catalog/product_info.php?products_id=28&osCsid=eaeb7n26sl996uh73cpdqsk2b4 has resulted in too many redirects. Clearing your cookies for this site or allowing third-party cookies may fix the problem. If not, it is possibly a server configuration issue and not a problem with your computer.

Posted

this should be in your htaccess file

 

 

Options +FollowSymLinks
RewriteEngine On 
RewriteBase /catalog/

RewriteRule ^(.*)-p-(.*).html$ product_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-c-(.*).html$ shop.php?cPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-m-(.*).html$ shop.php?manufacturers_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pi-(.*).html$ popup_image.php?pID=$2&%{QUERY_STRING}
RewriteRule ^(.*)-t-(.*).html$ articles.php?tPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-a-(.*).html$ article_info.php?articles_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-ip-(.*).html$ infopages.php?info_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pr-(.*).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pri-(.*).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-i-(.*).html$ information.php?info_id=$2&%{QUERY_STRING}

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Posted

Yes, I have managed to turn it off via admin. You can check it on site, now urls in catalog are in standard way like: http://unwireme.ru.swteh.ru/catalog/product_info.php?products_id=28

 

 

 

htaccess is there, but which info should be placed in file to allow mod rewrites?

Your mod rewrites were working. It helps to turn them off to do the troubleshooting, in my opinion. Monika is also right, only use ".unwireme.ru.swteh.ru" as the cookie domain in each instance. I think she simply made a typo when she said use the http.. Use only ".unwireme.ru.swteh.ru" as the cookie domain and see if it helps.

 

Then look and be sure you are not forcing cookie use in the Configuration -> Sessions, and you have true only for the last two lines on the list there, and you have a valid sessions directory.

 

See if any of that helps.

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Posted

this should be in your htaccess file

 

 

Options +FollowSymLinks
RewriteEngine On 
RewriteBase /catalog/

RewriteRule ^(.*)-p-(.*).html$ product_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-c-(.*).html$ shop.php?cPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-m-(.*).html$ shop.php?manufacturers_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pi-(.*).html$ popup_image.php?pID=$2&%{QUERY_STRING}
RewriteRule ^(.*)-t-(.*).html$ articles.php?tPath=$2&%{QUERY_STRING}
RewriteRule ^(.*)-a-(.*).html$ article_info.php?articles_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-ip-(.*).html$ infopages.php?info_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pr-(.*).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-pri-(.*).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}
RewriteRule ^(.*)-i-(.*).html$ information.php?info_id=$2&%{QUERY_STRING}

 

Such configuration already exists in my .htaccess file. I believe that it was placed there during installation.

Posted

I tried all the recommended actions and still no access to catalog.

I have found one suspicious thing in my admin control panel.

I have no product images there. When I check link, it shows reference like this:

http://unwireme.ru.swteh.ru/catalog/admin/catalog/images/linksyswrt54gl.jpg

 

So catalog is placed twice. Actual link should be: http://unwireme.ru.swteh.ru/catalog/images/linksyswrt54gl.jpg

 

Is it path misconfiguration in config.php?

Posted

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Posted

sorry ... my http:// cookie comment was to say WITHOUT obviously ... as I showed in my example ... thx for pointing it out, mark!!!

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Posted

sorry ... my http:// cookie comment was to say WITHOUT obviously ... as I showed in my example ... thx for pointing it out, mark!!!

 

It is mistype but I managed to understand it from context.

Posted

 

Please check my config files and please, show me where the error is. I have double-, triple-, quadruple- ... times checked this and followed all recommendation but still have no idea where I am wrong.

 

CATALOG\INCLUDE

 

<?php

define('HTTP_SERVER', 'http://unwireme.ru.swteh.ru');

define('HTTPS_SERVER', 'https://secure.unwireme.ru.swteh.ru');

define('ENABLE_SSL', false);

define('HTTP_COOKIE_DOMAIN', '.unwireme.ru.swteh.ru');

define('HTTPS_COOKIE_DOMAIN', '.secure.unwireme.ru.swteh.ru');

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

define('HTTPS_COOKIE_PATH', '/catalog/');

define('DIR_WS_HTTP_CATALOG', '/catalog/');

define('DIR_WS_HTTPS_CATALOG', '/catalog/');

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

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

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_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/catalog/');

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

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

 

 

CATALOG\ADMIN\INCLUDE

 

<?php

define('HTTP_SERVER', 'http://unwireme.ru.swteh.ru/');

define('HTTP_CATALOG_SERVER', 'http://unwireme.ru.swteh.ru/');

define('HTTPS_CATALOG_SERVER', 'http://unwireme.ru.swteh.ru/');

define('ENABLE_SSL_CATALOG', 'false');

define('DIR_FS_DOCUMENT_ROOT', '/home/u/unwiremeru/public_html/catalog/');

define('DIR_WS_ADMIN', 'catalog/admin/');

define('DIR_FS_ADMIN', '/home/u/unwiremeru/public_html/catalog/admin/');

define('DIR_WS_CATALOG', 'catalog/');

define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/catalog/');

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

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

define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

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', DIR_WS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');

define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');

define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

Posted

replace this

 

define('DIR_FS_DOCUMENT_ROOT', '/home/u/unwiremeru/public_html/catalog/');
define('DIR_WS_ADMIN', 'catalog/admin/');
define('DIR_FS_ADMIN', '/home/u/unwiremeru/public_html/catalog/admin/');
define('DIR_WS_CATALOG', 'catalog/');
define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/catalog/');

 

by this

 

 

define('DIR_FS_DOCUMENT_ROOT', '/home/u/unwiremeru/public_html/');
define('DIR_WS_ADMIN', 'catalog/admin/');
define('DIR_FS_ADMIN', '/home/u/unwiremeru/public_html/');
define('DIR_WS_CATALOG', 'catalog/');
define('DIR_FS_CATALOG', '/home/u/unwiremeru/public_html/');

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Posted

Thanks to all forum participants and active contributors, now it works!!! Even with SEO URLs turned on.

Problem was combination of errors in configure.php files and Rewritebase parameters.

Archived

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

×
×
  • Create New...