The files and directory structure must be uploaded to your web server. This can accomplished in several different ways. Use whatever method is most familiar to you, i.e., unzipping the zip archive to your local computer and using your favorite FTP program to upload those files, or using SSH to tar/unzip on your server to avoid the tedium of downloading and re-uploading.
The files can be uploaded to the document root, or any other subdirectory, like /catalog.
If you have never looked at the oscommerce archive before, the basic directory structure looks like this:
osCMax.zip
/catalog
/admin
First, upload the /catalog directory and all the directories and files it contains to your document root (public_html or www). When you are finished uploading, your basic directory tree should look like this:
/public_html
/catalog
/admin
/images
/includes
/download
/images
/includes
/install
Setting file permissions correctly will allow the installation script to write to the configure.php files. So, after they are uploaded you can use telnet, ssh, or your favorite FTP client to set the file permissions. CHMOD 777 will set the correct permissions for installation.
Using phpMyAdmin or other tool, create your database and user, and assign that user to the database.
This section provides instructions using phpMyAdmin to create a database and user, and assign that user to the database. These steps are necessary BEFORE you run the install script.
Watch Installation Video - This video shows the entire installation process start to finish.
Please ensure that you read everything in this section and also this page on setting up security.
This is important to ensure security of your configuration. CHMOD 444 the above files. This can be done through telnet, ssh, or an FTP client. If on a Windows server, you will need to right click the configure.php files and select 'properties' in the context menu. Once on the properties page, check the 'Read Only' checkbox, click Apply, and OK.
The most common cause of hacks is code inserted into unprotected files and folders.
However, if you are using suPHP on your server (ask your host if you are not sure or run this suPHP check) then …
These commands can be run from the linux command line or from an executable file via cronjob.
Here is the command run to set all directories:
find . -type d -exec chmod 755 {} ;
Here is the command run to set all php files:
find . -type f -name “*.php” | xargs chmod 644
With this permissions configuration, it is not secure to keep backups on your server. You should download the backup to your local computer, and never store the backup on the web server. Optional Password protect your /catalog/admin dir using .htaccess
Your admin section should be password protected. The easiest way to do this is to use .htpasswd and .htaccess to secure the directory. If you are not sure how to do this, please follow the procedure outlined below:
AuthType Basic
AuthName "Locked Area"
AuthUserFile /home/youraccount/.htpasswds/admin/passwd
require valid-user
See Also .htaccess Instructions and setting up security Add to your DirectoryIndex statement and include the following : index.php This can be done in the Apache httpd.conf file if you have root access, or can be done in an .htaccess file in your /catalog dir.
This is the .htaccess method for adding the DirectoryIndex statement.
This tells the server to look for index.php as the index page in the /catalog directory, so you can access your catalog by the url http://www.yoursite.com/catalog/ instead of having to include the filename like this http://www.yoursite.com/catalog/index.php.
Congratulations, you have completed all the necessary steps to successfully installing osCMax on your web server. You should be able to access your catalog at http://yoursite.com/catalog and your admin at http://yoursite.com/catalog/admin.
Only if you are running v2.0.2 or before go to : http://www.yoursite.com/catalog/admin/ where you will be presented with a login screen.
If you are installing an old version of osCMax (which you shouldn't) then: