Quick start
Installing the ShopAdmin add-on into osCommerce involves two essential steps:
- Download the zip file that you receive when you sign up, and unzip it into the admin folder of your osCommerce installation. This zip file is a package containing the following files:
apsona_config.php apsona_dashboard.js apsona_functions.php apsona_index.php apsona_init_filters.sql apsona_init_reports.sql apsona_JSON.php apsona_svc.php
All the files must be copied into your the admin folder of your osCommerce installation. This will set up ShopAdmin to be accessible via the URL
apsona_index.phpwithin your osCommerce system. - Access the URL apsona_index.php instead of index.php within your admin area. For example, after you log in,
if your store admin URL is
http://my-store.com/catalog/admin/index.phpthen your ShopAdmin URL ishttp://my-store.com/catalog/admin/apsona_index.phpThe first time you access the ShopAdmin URL, the add-on tries to create a link to the ShopAdmin window in your Admin Tools menu. It does this by trying to modify the file catalog/admin/includes/boxes/tools.php. The add-on might not succeed in doing so, depending on the file’s permissions and whether or not the file has already been modified. After you have accessed the ShopAdmin URL once, you can inspect this file and manually add the link if needed.
Note also that, unlike with many other osCommerce add-ons, you do not need to run the SQL files included in the package. ShopAdmin automatically detects whether they need to be run, and runs them if necessary. This approach is intentional, so as to make the installation process as easy as possible.
Troubleshooting
Sometimes the host configuration or the shopping cart setup prevents Apsona ShopAdmin from operating correctly. Here are some common errors and how you might be able to fix them.
- You might see a part of the ShopAdmin interface, with a banner and logo at the top, and no other elements. Some possible remedies:
- If you used Internet Explorer to access ShopAdmin, try using either Firefox, Google Chrome or Safari.
- Some hosting servers require that all the ShopAdmin PHP files should have their “execute” permission set. You can usually set this permission via the hosting control panel.
- ShopAdmin requires either (a) the PHP parameter
allow_url_fopento be set to “on” in your php.ini file, or (b) built-in PHP support for the curl module. You can verify the settings of these parameters by clicking Tools – Server/Version Info in your admin area, and looking in the PHP Core section under Configuration. Ifallow_url_fopenis set to “off”, you will need to change the setting via your hosting server’s control panel. With many hosting systems, you can set this value to “on” by creating a file namedphp.iniin your cart’s admin folder with the following contents:allow_url_fopen = on;
- When the new ShopAdmin window opens, it might display either a completely blank white page. This can happen if either you have an older version of PHP (earlier than 5.0) or an older version of MySQL (earlier than 5.0). ShopAdmin requires PHP version 5.1 or better, and MySQL version 5.0 or better. With some hosting services, you can upgrade easily to PHP 5.0 (see next item below). But if you have an older MySQL version, you probably need to contact your hosting service for an upgrade.
- When the new ShopAdmin window opens, it might display an error like this:
Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in apsona_functions.php on line 15
This typically happens if you are using an older version of PHP, such as PHP 4.3. ShopAdmin requires PHP 5.1 or better. The PHP version is determined by your hosting service. With many hosting systems, you can enable PHP 5 by creating a file named
.htaccessin your admin folder with the following contents (or if the file already exists, adding these to lines to its end):AddType x-mapp-php5 .php AddHandler x-mapp-php5 .php
If none of these measures help, please contact us and we will gladly help get you going.
User-contributed comments
Brent from New Zealand contributed these comments to get ShopAdmin working with OsCommerce version 2.3.1:
Getting Apsona ShopAdmin to go when you have renamed your admin folder.
When you change your admin folder name, make the necessary changes in admin/includes/configure.php – pointing to your new admin folder name and uploading it should now go to your admin area.
catalog/XXXX/includes/configure.php
change code: present around lines 7 – 8 (YYYY – was my folder catalog was in – will be root for most).
define(‘DIR_WS_ADMIN’, ‘/YYYY/catalog/admin_444/’);
define(‘DIR_FS_ADMIN’, ‘/var/www/html/YYYY/catalog/admin_444/’);
change to this and upload:
define(‘DIR_WS_ADMIN’, ‘/YYYY/catalog/XXXX/’);
define(‘DIR_FS_ADMIN’, ‘/var/www/html/YYYY/catalog/XXXX/’);
####################### Example ########################################
http://www.yourdomain.com/catalog/XXXX/login.php
XXXX is your new admin folder name.
Select Tools and where you see Aspona ShopAdmin when you hover over it (I use firefox) it will show at the bottom of the window where the link wants to go to. Unfortunately it wants to go to catalog/admin/apsona_index.php – THIS IS WRONG!!
####################### How to fix ########################################
XXXX/includes/boxes/tools.php (XXXX is your newly named admin folder)
scroll down until you see this:
'<a href="' . tep_href_link(FILENAME_WHOS_ONLINE) . '" class="menuBoxContentLink">' . BOX_TOOLS_WHOS_ONLINE . '</a>');
}
replace with this and upload:
'<a href="' . tep_href_link(FILENAME_WHOS_ONLINE) . '" class="menuBoxContentLink">' . BOX_TOOLS_WHOS_ONLINE . '</a><br>' .
'<a href="http://www.yourdomain.com/YYYY/catalog/XXXX/apsona_index.php" target="_blank" title="Apsona ShopAdmin">Apsona ShopAdmin</a>');
}
####################### See it working ####################################
Go back to your Admin area (backend for oScommerce) and press F5 and go to tools again and select Aspona ShopAdmin.
It should now to go Aspona. If it doesn’t… again I use Firefox clear cookies and history via Tools/Options on the Firefox menu bar.