Site Panel Help User Panel Help Panel Demo's Search Help

Categories

· Show all categories

New Customer FAQs
E-Mail
FTP - File Transfers
Domains
SSH and Telnet
Scripting Languages
Password Protection
MySQL
Stats
Power Tools

· FAQ Home

· EchoEcho+ Support

Power Tools: POWERTOOL: osCommerce
On this page you can find solutions to known and common problems with osCommerce.


IMAGES NOT DISPLAYING
On some servers, the default permission for uploaded files are non-viewable. Since osCommerse does not specify the permissions for images uploaded through the admin login, you may therefore need to update the code.

If you can't view the images that are uploaded by osCommerce, you need to modify the admin/includes/functions/general.php file.

Look for this (around line 784):
function tep_copy_uploaded_file($filename, $target) {
if (substr($target, -1) != '/') $target .= '/';
$target .= $filename['name'];
move_uploaded_file($filename['tmp_name'], $target);
}



and add this to the end:
chmod ("$target", 0644);



so it should look like this:
function tep_copy_uploaded_file($filename, $target) {
if (substr($target, -1) != '/') $target .= '/';
$target .= $filename['name'];
move_uploaded_file($filename['tmp_name'], $target);
chmod ("$target", 0644);
}





How do I enable https / SSL for osCommerce?

The configuration is stored in two files:
Inside your osCommerce folder, you will find these files:
----------------------------
admin/includes/configure.php
includes/configure.php
----------------------------

Both files are "read-only" by default.
You need to change the file permissions so the owner can read and write to the files.
Otherwise you won't be able to save the updated files.
This can be done with an FTP program, using the "chmod" options.
(Chmod them to 755 while editing them, and back to 400 when done.)

The exact procedure to follow depends on your FTP program.
You can read about chmod and permissions in the FTP FAQ.

Once you have changed the permissions, you can make the changes to the config files.
You need to change the lines where HTTPS_SERVER, ENABLE_SSL and HTTPS_COOKIE_DOMAIN are defined.
The lines should look like this:
---------------
define('HTTPS_SERVER', 'https://echoX.echoechoplus.com/example.com');
define('ENABLE_SSL', true);
define('HTTPS_COOKIE_DOMAIN', '');
---------------

You need to replace "echoX" with the real name of your server, eg. echo8.
(If you don't know what your server name is, you can login to your site owner panel.
On the login page, the servername is at the beginning of the URL.)

You also need to replace "example.com" with your real domain name.

When you've edited both files, you need to set the permissions back to "read-only".

That's it!

Last update: 12.07.2009, 21:21
Author: EchoEcho Support

printer-friendly version Send to a friend
Show this as PDF file export as XML-File

Average rating: 3.75 from 5 (4 Votes )

Please rate this entry:
completely
useless

1

2

3

4

5
most
valuable
You cannot comment on this entry | Content Overview: Power Tools
Copyright © EchoEchoPlus Hosting