How to Install TomatoCart on Your Arvixe Web Server

This article is written for the Arvixe users who wish to install TomatoCart Opensource Shopping Cart on their web server.

Requirements


TomatoCart Open Source Shopping Cart can be installed on any PHP enabled web server that can connect to a MySQL database such as Arvixe.

  • PHP
  • MySQL Database Server

php


TomatoCart Opensource Shopping Cart is compatible with PHP 4 and PHP 5. For performance and security reasons, it is recommended to use the latest PHP 5 version on your web server. The following PHP options are recommended to be set in the php.ini configuration file:

safe_mode Off
register_globals Off
magic_quotes_gpc Off
file_uploads On
session.auto_start Off
session.use_trans_sid Off

The following PHP extensions are mandatory:

Mysql MySQL database extension.

The following PHP extensions are recommended:

GD Image processing module.
cURL Network communication library.
OpenSSL Encryption library.

MySQL Database Server


The minimum MySQL version required is v3.23. It is recommended to use the latest MySQL 4 or MySQL 5 version on the database server. The following MySQL storage engines are supported:

MyISAM Default storage engine.

Pre-Installation Steps


TomatoCart Opensource Shopping Cart is a web based solution that needs its relevant files to exist on the web server. The files can be copied to the web server by extracting the download package on your computer and uploading its contents to the web server via FTP, or by copying the download package to the web server directly and extracting its contents there.

Copying the Files to the Web Server


Go to http://www.tomatocart.com/downloads/download-tomatocart.html to download the TomatoCart package. The contents of the download package need to be copied to the public HTML directory the web server is serving from. For the Arvixe web server, the directory is: /home/server_owner_name/public_html/The contents of the download package once extracted is:

  • admin(Directory)
  • cache(Directory)
  • download(Directory)
  • ext(Directory)
  • images(Directory)
  • includes(Directory)
  • install(Directory)
  • templates(Directory)
  • .htaccess
  • account.php
  • checkout.php
  • download.php
  • index.php
  • info.php
  • INSTALL.TXT
  • json.php
  • LICENSE.txt
  • pdf.php
  • products.php
  • redirect.php
  • RELEASE.txt
  • robots.txt
  • rss.php
  • search.php
  • sitemapsArticles.xml
  • sitemapsCategories.xml
  • sitemapsIndex.xml
  • sitemapsProducts.xml

Using FTP to Copy the Download Package Contents to the Arvixe Web Server

FTP accounts allow you to access your website’s files through a protocol called FTP. You will need a third-party FTP program to access your files. It is simple to create the ftp account in the Arvixe Control panel as follows:

  1. Login into your Arvixe Control Panel. (Once you buy the hosting service on the Arvixe, they will allow you to access your personal cPanel with the username and password.)
  2. Click the Ftp Account Icon in the Arvixe cPanel to create the ftp account.
    Arvixe Control Panel
    Figure 1. Arvixe Control Panel
    Figure 2. Create Ftp Account

The download package of TomatoCart Opensource Shopping Cart should be saved and extracted on your computer to reveal its contents. All the contents of the download package must be copied to the public HTML directory on your Arvixe web server. This can be achieved on most FTP clients by dragging all the contents of the package from your local file browser panel to the remote panel listing the files on the web server.

Note: All PHP files must be uploaded in ASCII mode (not in Binary mode).

Directly Extracting the Download Package on the Arvixe Web Server

It is easy to upload the download package to the public html directory and extract the package in the Arvixe Control Panel as follows:

  1. Login into your Arvixe Control Panel. (Once you buy the hosting service on the Arvixe, they will allow you to access your personal cPanel with the username and password.)
  2. Click the File Manager Icon in the Arvixe cPanel. In the File Manager panel, it is possible to upload the download package by clicking the Upload icon.
    Arvixe Control Panel
    Figure 3. Arvixe Control Panel
    Figure 4. File Manager Panel
    Figure 5. Upload Files

File Permissions


The following files need to be writable by the web server.

Files Web Server Writable
sitemapsIndex.xml Writable
sitemapsCategories.xml Writable
sitemapsProducts.xml Writable
sitemapsArticles.xml Writable
includes/configure.php Writable
ext/piwik/config/config.ini.php Writable

The following directories need to be writable by the web server.

Directories Web Server Writable
admin/images Writable
admin/backups Writable
cache Writable
cache/admin Writable
cache/admin/emails Writable
cache/admin/emails/attachments Writable
cache/orders_customizations Writable
cache/products_attachments Writable
cache/products_customizations Writable
download Writable
images Writable
images/articles Writable
images/articles/large Writable
images/articles/mini Writable
images/articles/originals Writable
images/articles/product_info Writable
images/articles/thumbnails Writable
images/products Writable
images/products/large Writable
images/products/mini Writable
images/products/originals Writable
images/products/product_info Writable
images/products/thumbnails Writable
images/categories Writable
images/manufacturers Writable
includes/work Writable
includes/logs Writable
templates Writable
ext/piwik/ Writable
ext/piwik/config Writable
ext/piwik/tmp Writable
ext/piwik/tmp/cache Writable
ext/piwik/tmp/templates_c Writable
admin/includes/languages Writable
includes/languages Writable
install/includes/languages Writable
install/templates/main_page/languages Writable

Note: The includes/configure.php file must have its web server writable permission removed after the installation procedure has completed successfully.

Please consult with your hosting provider – Arvixe for the correct permission flag to allow the web server to write to those files. This is commonly defined with a permission flag of 755.

Note: In some cases a world write permission flag of 777 can be used but may lead to an insecure installation of TomatoCart Opensource Shopping Cart.

Changing the file permissions can be performed by most FTP clients or directly on the Arvixe web.

Using FTP to Change File Permissions

Most FTP clients are capable of changing file permissions on the web server. This is commonly performed by right-clicking on the file and selecting “Properties” or “Attributes” on the context menu. The file permissions can be changed by allowing all users to read, write, and execute the file, or by manually entering the world readable and world writable flag of 777.

Changing File Permissions Directly on the Arvixe Server as follows:

    1. Click the File Manager icon.
    2. Find the file and directory in the file manager panel.
    3. Click the Change Permission Icon in the top menu or right click the file or directory to select the Change Permission menu.
      Change Permission In File Manager Panel
      Figure 6. Arvixe Control Panel
      Change Permission Dialog
      Figure 7. Change Permission Dialog

    4. It is also possible to use the following command to change permission on the Arvixe Server:

chmod -R 777 /path/to/public/html/directory/file

Database


A MySQL database on the web server or database server is required for the installation procedure to successfully import the database table structure and required data settings. It is efficient to create a database for installing the TomatoCart Opensource Shopping Cart on the Arvixe server as follows:

  1. Find the MySQL Database icon in the Arvixe cPanel and then click it.
    Mysql Database in the Arvixe cPanel
    Figure 8. Mysql Database in the Arvixe cPanel

  2. Create the new database for TomatoCart installation. You just need to enter the username and password. The password could be set manually or generated automatically through clicking the Password Generator. After that, please just click the Create User button.
    Create the new database for TomatoCart installation
    Figure 9. Create the new database for TomatoCart installation

  3. Add user to database by linking the user to the database created above.
    Add user to database
    Figure 10. Add user to database

  4. Manage the user privilege for the new database user created above.
    Manage the user priviledge
    Figure 11. Manage the user privilege

Web Server and Database Server Details


The following web server and database server details are required during the installation procedure. Please consult the Arvixe hosting provider if these details are not known.

Web Server Details

Setting Description Possible Value
Server Address The web address to the online store. http://www.example.com/
Root Directory The directory where the online store is installed on the web server. /home/your_directory/public_html/

Database Server Details

Setting Description Possible Value
Server Address he address of the database server in the form of a hostname or IP address. localhost
Username The username used to connect to the database server. your_database_username
Password The password that is used together with the username to connect to the database server. your_secure_password
Database Name The name of the database to hold the data in. tomatocart

Installation Procedure


The web based installation procedure configures the online store and imports the configuration data into the database. This is necessary to create a fully functional online store and to create an administrator that administrates the online store through the Administration Tool. The configuration values provided by default are safe to use but may need to be changed depending on your detailed requirement.

  • Installing a New Online Store with TomatoCart Opensource Shopping Cart
  • Licence agreement
  • Pre-installation Check
  • Database Setup
  • Web Server Setup
  • Online Store Settings
  • Finished

Installing a New Online Store with TomatoCart Opensource Shopping Cart


The web based installation procedure is automatically started when accessing the online store through a web browser. This can be achieved by entering the WWW address of TomatoCart Opensource Shopping Cart in your browser. For example:

http://www.tomatocart.com

TomatoCart Opensource Shopping Cart automatically detects if the installation has already been completed and redirects to the installation procedure if it has not yet been performed.

Step 1: Licence Agreement


The first step is the TomatoCart Licence Agreement shown in Figure 12 which introduce the TomatoCart and announce the License for TomatoCart.

Licence Agreement
Figure 12. Licence Agreement

Step 2: Pre-installation Check


The second step shown in figure 13 make sure your system does meet the minimum requirements for installation.

Pre-installation Check
Figure 13. Pre-installation Check

Step 3: Database Setup


The second step shown in Figure 14 sets the database connection parameters to successfully connect to the database server, to import the database table structure, and to import required data. The database server stores the content of the online store such as product information, customer information, and the orders that have been made etc.

Database Setup
Figure 14. Database Setup

The installation procedure verifies the values entered before proceeding to the next step. If there is a problem connecting to the database server an error message is shown similar to the message shown in Figure 15.

Database Setup Error
Figure 15. Database Setup Error

Check to make sure the correct username, password, and database name are listed.

Step 4: Web Server Setup


The fourth step shown in Figure 16 sets the web server parameters to successfully serve the online store to users. The web server takes care of serving the pages of the online store to the visitors and customers. The web server parameters make sure the links to the pages point to the correct location. Temporary files such as session data and cache files are stored in the work directory. It is important that this directory is located outside the web server root directory and is protected from public access.

Web Server Setup
Figure 16. Web Server Setup

Step 5: Online Store Settings


The fifth step shown in Figure 17 sets the store owner and administrator settings for the online store.

Online Store Settings
Figure 17. Online Store Settings

It is important to keep note of the administrator username and password as these are used to login and to access the Administration Tool.

Additional administrators can be created in the Administration Tool after the installation procedure has been successfully completed.

Step 6: Finished


The last step in the installation procedure stores the database server and web server parameters to the configuration file on the web server. On successfully saving the configuration file, the installation procedure is finalized and the online store is ready to be used as shown on Figure 18.

Finished
Figure 18. Finished

Post-Installation Steps


Upon successful installation of TomatoCart Opensource Shopping Cart, the following steps need to be performed to secure the installation of the online store.

  • Remove Installation Files
  • Reset File and Directory Permissions
    • Configuration Files
    • Writable Directories
  • Extra Protection for the Administration Tool

Remove Installation Files


The install directory must be removed from the web server otherwise a user could use the installation procedure and reconfigure the online store to use another database server.

Reset File and Directory Permissions


Configuration Files

The file permissions on includes/configure.php must be set to deny write access by the web server service. This is commonly performed by setting the permission flag to a read only value of 644 or 444.

Writable Directories

The following directories must be set to allow the web server service to write to for the Administration Tool to function properly. This is commonly performed by setting the permission flags to a world-writable value of 777.

Directories Web Server Writable
images Writable
admin/images Writable
admin/backups Writable
cache Writable
download Writable
includes/work Writable
includes/languages Writable
admin/includes/languages Writable
admin/includes/languages Writable
ext/piwik/tmp Writable
ext/piwik/tmp/cache Writable
ext/piwik/tmp/templates_c Writable

Extra Protection for the Administration Tool


The Administration Tool is secured by its own login routine but is still publicly accessible. For security reasons, it is recommended to further protect the Administration Tool as follows:

  • Setting a htaccess password on the admin directory.
  • Renamed the admin directory to another name that is more difficult to guess by the hacker. Once you rename the admin directory, it is necessary to modify the DIR_FS_ADMIN with the new directory name defined in includes/configure.php.

Now, the whole installation procedure is completed. Congratulations on installing and configuring TomatoCart as your online store solution! We welcome you to join and participate in our community.

Looking for quality TomatoCart  Web Hosting? Look no further than Arvixe Web Hosting!

Tags: , , , , , , | Posted under TomatoCart | RSS 2.0

Author Spotlight

Jack Yin

Jack Yin

TomatoCart Developer & Co Founder - Arvixe Web Hosting / TomatoCart Community Liaison

Leave a Reply

Your email address will not be published. Required fields are marked *


5 + 8 =

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>