Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

1.

What We Do If The Requested Url /account.php Was Not Found On This Server?

Answer»

This issue is most commonly caused by incorrectly configured SSL settings for your OS Commerce. If you don not have private SSL and your OS Commerce is enabled you will receive this error.

Enabling/disabling SSL in osCommerce is quite straightforward. You have to edit /includes/configure.php to disable SSL and the CODE takes CARE of the rest. This is an example of SSL enabled configuration:

// Define the webserver and path PARAMETERS
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)

define('HTTP_SERVER', 'HTTP://www.yourdomain.com'); // eg, http://localhost - should not be empty for productive servers

define('HTTPS_SERVER', 'https://yourdomain.com'); // eg, https://localhost - should not be empty for productive servers

define('ENABLE_SSL', true); // secure webserver for checkout procedure?

define('HTTP_COOKIE_DOMAIN', 'www.yourdomain.com');
define('HTTPS_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTP_COOKIE_PATH', '/catalog/');
define('HTTPS_COOKIE_PATH', '/catalog/');
define('DIR_WS_HTTP_CATALOG', '/catalog/');
define('DIR_WS_HTTPS_CATALOG', '/catalog/');
In order to disable the SSL you will have to replace
define('ENABLE_SSL', true);
with
define('ENABLE_SSL', false);

This issue is most commonly caused by incorrectly configured SSL settings for your OS Commerce. If you don not have private SSL and your OS Commerce is enabled you will receive this error.

Enabling/disabling SSL in osCommerce is quite straightforward. You have to edit /includes/configure.php to disable SSL and the code takes care of the rest. This is an example of SSL enabled configuration:

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)

define('HTTP_SERVER', 'http://www.yourdomain.com'); // eg, http://localhost - should not be empty for productive servers

define('HTTPS_SERVER', 'https://yourdomain.com'); // eg, https://localhost - should not be empty for productive servers

define('ENABLE_SSL', true); // secure webserver for checkout procedure?

define('HTTP_COOKIE_DOMAIN', 'www.yourdomain.com');
define('HTTPS_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTP_COOKIE_PATH', '/catalog/');
define('HTTPS_COOKIE_PATH', '/catalog/');
define('DIR_WS_HTTP_CATALOG', '/catalog/');
define('DIR_WS_HTTPS_CATALOG', '/catalog/');
In order to disable the SSL you will have to replace
define('ENABLE_SSL', true);
with
define('ENABLE_SSL', false);

2.

How To Install A Different Template To An Existing Oscommerce?

Answer»

osCommerce does not support a template installer option, as Joomla CMS or phpBB forum do, for INSTANCE. Installing a NEW template for osCommerce is actually a new installation of the osCommerce files.

The installation of the template will not affect your database which MEANS you will not lose your DATA and products.

osCommerce does not support a template installer option, as Joomla CMS or phpBB forum do, for instance. Installing a new template for osCommerce is actually a new installation of the osCommerce files.

The installation of the template will not affect your database which means you will not lose your data and products.

3.

Zencart / Oscommerce / Creloaded Shows Security Warnings.?

Answer»

After a ZenCart / OSCOMMERCE / CRELoaded installation you may RECEIVE the following warning:

"Warning: I am able to write to the configuration file: /home/user/public_html/includes/configure.php. This is a POTENTIAL security risk..."

In order to fix this issue you can follow these steps:

  • Log in your cPanel and go to the File manager;
  • First navigate to your store's DIRECTORY and then go to the includes directory where you will find the configure.php file;
  • Click on the file in question and from the top right menu change its permissions to 444;
  • You will have to change similarly the permissions of the file configure.php in your store's admin/includes directory.

After a ZenCart / osCommerce / CRELoaded installation you may receive the following warning:

"Warning: I am able to write to the configuration file: /home/user/public_html/includes/configure.php. This is a potential security risk..."

In order to fix this issue you can follow these steps:

4.

Oscommerce Does Not Use The Private Ssl?

Answer»

After PURCHASING your private SSL you have to manually reconfigure your application to USE it.

After purchasing your private SSL you have to manually reconfigure your application to use it.

5.

How To Install Ecommerce On My Hosting Account?

Answer»

By default all Siteground accounts COME with no pre-installed APPLICATIONS. An ECOMMERCE pack may include several features and most OFTEN begins with an OsCommerce, a CreLoaded or a ZENCART installation.

By default all Siteground accounts come with no pre-installed applications. An Ecommerce pack may include several features and most often begins with an OsCommerce, a CreLoaded or a Zencart installation.

6.

How To Configure Oscommerce To Work With Ssl?

Answer»

In order to configure osCommerce to work with SSL you should OPEN the file public_html/catalog/includes/configure.php and make the following changes:

define('HTTP_SERVER', 'HTTP://www.yourdomain.com'); // EG, http://localhost - should not be empty for productive servers
define('HTTPS_SERVER', 'https://yourdomain.com'); // eg, https://localhost - should not be empty for productive servers
define('ENABLE_SSL', true); // SECURE webserver for checkout procedure
define('HTTP_COOKIE_DOMAIN', 'www.yourdomain.com');
define('HTTPS_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTP_COOKIE_PATH', '/catalog/');
define('HTTPS_COOKIE_PATH', '/catalog/');
define('DIR_WS_HTTP_CATALOG', '/catalog/');
define('DIR_WS_HTTPS_CATALOG', '/catalog/');

Similar to the above changes have to be made in the file public_html/catalog/admin/includes/configure.php which is RESPONSIBLE for the admin area configuration.

In the above example we are configuring an osCommerce installation in the catalog directory with domain yourdomain.com. You should adjust the above settings to your details.

In order to configure osCommerce to work with SSL you should open the file public_html/catalog/includes/configure.php and make the following changes:

define('HTTP_SERVER', 'http://www.yourdomain.com'); // eg, http://localhost - should not be empty for productive servers
define('HTTPS_SERVER', 'https://yourdomain.com'); // eg, https://localhost - should not be empty for productive servers
define('ENABLE_SSL', true); // secure webserver for checkout procedure
define('HTTP_COOKIE_DOMAIN', 'www.yourdomain.com');
define('HTTPS_COOKIE_DOMAIN', 'yourdomain.com');
define('HTTP_COOKIE_PATH', '/catalog/');
define('HTTPS_COOKIE_PATH', '/catalog/');
define('DIR_WS_HTTP_CATALOG', '/catalog/');
define('DIR_WS_HTTPS_CATALOG', '/catalog/');

Similar to the above changes have to be made in the file public_html/catalog/admin/includes/configure.php which is responsible for the admin area configuration.

In the above example we are configuring an osCommerce installation in the catalog directory with domain yourdomain.com. You should adjust the above settings to your details.

7.

How To Generate The Necessary Certificates For Paypal Ipn?

Answer»

The PayPal IPN contribution for osCommerce offers OpenSSL public/private KEY encryption to securely send the order information to PayPal during checkout.

Here is information on how to generate the necessary certificates:

  1. You should have OpenSSL INSTALLED on your computer. Linux distrubutions should have it installed by default, and a Windows version can be downloaded from here.
  2. You should generate a private key using this command:

    openssl genrsa -out my-prvkey.pem 1024

    This will create a 1024-bit RSA private key in the file my-prvkey.pem.

  3. You should generate a public certificate using this command:

    openssl req -new -key my-prvkey.pem -x509 -days 365 -out my-pubcert.pem

    This will create a public certificate in the file my-pubcert.pem.

  4. Then you should upload your public certificate to the PayPal website:

    4.1. Log in to your PayPal account.
    4.2. Click the Profile tab.
    4.3. In the Seller Preferences column you should click the ENCRYPTED Payment Settings link. The Website Payment Certificates PAGE should appear.
    4.4. Scroll down to the Your Public Certificates section and click the Add button. The Add Certificate page should appear.
    4.5. Click the Browse button and select the public certificate that you want to upload to PayPal from your local computer.
    4.6. Click the Add button. After you upload the public certificate successfully, it appears in the Your Public Certificates section of the Website Payment Certificates page.

  5. A certificate ID will be assigned to your public certificate. You need this certificate ID to encrypt your payment buttons by using PayPal's Encrypted Website PAYMENTS program.

The PayPal IPN contribution for osCommerce offers OpenSSL public/private key encryption to securely send the order information to PayPal during checkout.

Here is information on how to generate the necessary certificates:

8.

How To Add A Banner In Oscommerce?

Answer»

You can EASILY add a custom banner to your OSCOMMERCE shop from the APPLICATION's ADMIN area > Tools > Banner Manager.

You can easily add a custom banner to your osCommerce shop from the application's admin area > Tools > Banner Manager.

9.

How To Transfer My Oscommerce From One Host To Another?

Answer»

Transferring your osCommerce application INCLUDES copying your files and database and modifying the two configure.php files in includes/ and ADMIN/includes/ folders to work with the new server settings.

The most IMPORTANT settings which should be MODIFIED in includes/configure.php are:

  • HTTP_SERVER - you should set this to your domain name, e.g. http://yourdomain.com:

    define('HTTP_SERVER', 'http://yourdomain.com');

  • DIR_FS_CATALOG - the absolute path to your shop, e.g. /home/user/public_html/shop/:

    define('DIR_FS_CATALOG', '/home/user/public_html/shop');

  • DB_SERVER - you should set this to localhost:

    define('DB_SERVER', 'localhost');

  • DB_SERVER_USERNAME - the username with privileges to access the shop database:

    define('DB_SERVER_USERNAME', 'user_osc1');

  • DB_SERVER_PASSWORD - the password for accessing the database:

    define('DB_SERVER_PASSWORD', 'oscpassword');

  • DB_DATABASE - the shop database:

    define('DB_DATABASE', 'user_osc1');

  • In admin/includes/configure.php, ALONG with the settings above, you should also modify:
  • DIR_FS_DOCUMENT_ROOT - the absolute path to your shop, e.g. /home/user/public_html/shop/:

    define('DIR_FS_DOCUMENT_ROOT', '/home/user/public_html/shop/');

  • DIR_FS_ADMIN - the absolute path to the admin folder, e.g. /home/user/public_html/shop/admin/:

    define('DIR_FS_ADMIN', '/home/user/public_html/shop/admin/');

Transferring your osCommerce application includes copying your files and database and modifying the two configure.php files in includes/ and admin/includes/ folders to work with the new server settings.

The most important settings which should be modified in includes/configure.php are:

10.

I’m Getting A 1054 Error In My Oscommerce After A Website/account Transfer?

Answer»

Sometimes, after a website or account transfer, your osCommerce may give a 1054 - Unknown column 'p.products_id' in 'on clause' error when browsing your products or when using the SEARCH tool.

The most common reason for this issue is that your account has been moved from a server running MySQL 4 to a server running MySQL 5.

As a solution, you can try applying this osCommerce contribution.

In most cases, this will RESOLVE the 1054 problem. If, however, the problem persists, the best solution would be to have your account migrated to a server running MySQL 4.

Sometimes, after a website or account transfer, your osCommerce may give a 1054 - Unknown column 'p.products_id' in 'on clause' error when browsing your products or when using the search tool.

The most common reason for this issue is that your account has been moved from a server running MySQL 4 to a server running MySQL 5.

As a solution, you can try applying this osCommerce contribution.

In most cases, this will resolve the 1054 problem. If, however, the problem persists, the best solution would be to have your account migrated to a server running MySQL 4.

11.

How Can I See The Exact Version Of My Oscommerce?

Answer»

In ORDER to check the VERSION of your osCommerce, you should open the includes/application_top.php FILE located in your osCommerce installation folder.

Look for these two lines:

// define the project version

define('PROJECT_VERSION', 'osCommerce Online Merchant v2.2 RC2a');

The VALUE after PROJECT_VERSION defines your CURRENT osCommerce version.

In order to check the version of your osCommerce, you should open the includes/application_top.php file located in your osCommerce installation folder.

Look for these two lines:

// define the project version

define('PROJECT_VERSION', 'osCommerce Online Merchant v2.2 RC2a');

The value after PROJECT_VERSION defines your current osCommerce version.

12.

E-commerce Application Comparison: Oscommerce Vs Zen Cart?

Answer»

osCommerce and Zen Cart are two of the most popular free shopping cart solutions. But which one is better? Which one of these two would be more suitable for your needs. In this article we have TRIED to make a comparison between osCommerce and Zen Cart.

osCommerce:

pros:

  • easy installation;
  • a lot of additional contributions which greatly expand the application's functionality;
  • sufficient documentation and FORUM support;

 CONS:

  • the installation of most contributions requires changes in the application's code and this may lead to problems;
  • new versions and upgrades are released very rarely;
  • older versions do not work properly with MySQL 5;
  • the installation of a new template is actually a complete new osCommerce installation;
  • upgrading osCommerce is not an easy task; 

Zen Cart:

pros:

  • easier to use with more intuitive admin AREA;
  • more secure;
  • more modules included in the default installation;

cons:

  • MEDIOCRE default templates;
  • upgrading Zen Cart is not an easy task either;
  • fewer additional modules/contributions;

osCommerce and Zen Cart are two of the most popular free shopping cart solutions. But which one is better? Which one of these two would be more suitable for your needs. In this article we have tried to make a comparison between osCommerce and Zen Cart.

osCommerce:

pros:

 cons:

Zen Cart:

pros:

cons:

13.

E-commerce Application Comparison: Oscommerce Vs Cre Loaded?

Answer»

In this we will list the most important pros and cons of osCommerce and CRE Loaded Standard. Hopefully, this will help you in your choice of a free shopping cart application.

CRE Loaded:

pros:

  • very easy to use;
  • the standard INSTALLATION INCLUDES a lot of extra modules;
  • well-organized admin area;
  • better templates and template management;
  • easy to upgrade;

cons:

  • some of the default modules are rarely used;
  • on the other hand, some useful modules are part of the paid CRE Loaded package;

osCommerce:

pros:

  • easy installation;
  • a lot of additional CONTRIBUTIONS which greatly expand the application's functionality;
  • sufficient documentation and forum support;

 cons:

  • the installation of most contributions requires changes in the application's code and this may lead to problems;
  • new VERSIONS and UPGRADES are released very rarely;
  • older versions do not work properly with MySQL 5;
  • the installation of a new template is actually a complete new osCommerce installation;
  • upgrading osCommerce is not an easy task;

In this we will list the most important pros and cons of osCommerce and CRE Loaded Standard. Hopefully, this will help you in your choice of a free shopping cart application.

CRE Loaded:

pros:

cons:

osCommerce:

pros:

 cons:

14.

How To Configure Oscommerce To Work With A New Domain?

Answer»

In order to CONFIGURE OSCOMMERCE to work properly with another DOMAIN, you should modify the two configure.php files in includes/ and admin/includes/ folders to reflect the new domain.

The settings that should be changed in includes /configure.php are:

HTTP_SERVER - you should CHANGE this to your new domain name, e.g. http://newdomain.com:
define('HTTP_SERVER', 'http://newdomain.com');
HTTP_COOKIE_DOMAIN - again, this should be changed to reflect your new domain name:
define('HTTP_COOKIE_DOMAIN', 'newdomain.com');
If you are using SSL you should also modify:

HTTPS_SERVER - for example:

define('HTTPS_SERVER', 'https://newdomain.com');
HTTPS_COOKIE_DOMAIN - SET this to:
define('HTTPS_COOKIE_DOMAIN', 'newdomain.com');
In admin/includes/configure.php you should modify:
HTTP_SERVER - you should change this to your new domain name, e.g. http://newdomain.com:
define('HTTP_SERVER', 'http://newdomain.com');
HTTP_CATALOG_SERVER - again, this should be changed to your new domain name:
define('HTTP_CATALOG_SERVER', 'http://newdomain.com');
If you are using SSL, you should also change HTTPS_CATALOG_SERVER to:
define('HTTPS_CATALOG_SERVER', 'https://newdomain.com');

In order to configure osCommerce to work properly with another domain, you should modify the two configure.php files in includes/ and admin/includes/ folders to reflect the new domain.

The settings that should be changed in includes /configure.php are:

HTTP_SERVER - you should change this to your new domain name, e.g. http://newdomain.com:
define('HTTP_SERVER', 'http://newdomain.com');
HTTP_COOKIE_DOMAIN - again, this should be changed to reflect your new domain name:
define('HTTP_COOKIE_DOMAIN', 'newdomain.com');
If you are using SSL you should also modify:

HTTPS_SERVER - for example:

define('HTTPS_SERVER', 'https://newdomain.com');
HTTPS_COOKIE_DOMAIN - set this to:
define('HTTPS_COOKIE_DOMAIN', 'newdomain.com');
In admin/includes/configure.php you should modify:
HTTP_SERVER - you should change this to your new domain name, e.g. http://newdomain.com:
define('HTTP_SERVER', 'http://newdomain.com');
HTTP_CATALOG_SERVER - again, this should be changed to your new domain name:
define('HTTP_CATALOG_SERVER', 'http://newdomain.com');
If you are using SSL, you should also change HTTPS_CATALOG_SERVER to:
define('HTTPS_CATALOG_SERVER', 'https://newdomain.com');

15.

How To Optimize Oscommerce For Better Performance?

Answer»

osCommerce is one of the most popular free shopping cart APPLICATIONS currently available.

Here are some tips on how to improve the performance of your osCommerce shopping cart:

  • Check your website using this online tool. It will GIVE you valuable information on what modifications can be MADE in order to improve its performance.
  • Reduce the number of products shown on your main page.
  • Optimize your osCommerce database.
  • Keep the number of additional contributions as low as possible. Install only the most necessary ones.
  • Disable all default osCommerce features you are not using.
  • Keep the number of EXTERNAL LINKS as low as possible.

osCommerce is one of the most popular free shopping cart applications currently available.

Here are some tips on how to improve the performance of your osCommerce shopping cart:

16.

What Are Oscommerce Admin Login Problems?

Answer»

If you cannot log into your OsCommerce admin area try the following:

  1. Open your OsCommerce database through PhpMyAdmin. If you are not sure which it is check the file includes/configure.php and look for a constant called 'DB_DATABASE'.
  2. Run the following TWO queries:
    CREATE TABLE IF NOT EXISTS administrators (
    ID int(11) NOT NULL auto_increment,
    user_name varchar(32) NOT NULL,
    user_password varchar(40) NOT NULL,
    PRIMARY KEY (id)
    ) ;
    INSERT INTO administrators (id, user_name, user_password) VALUES
    (1, 'adm', '2272bd2219e0bbc353e33f1e774c9d1e:11');

  3. The above will create a new administrator with login 'adm' and password 'pass11'.

If you cannot log into your OsCommerce admin area try the following:

17.

Oscommerce Security Check?

Answer»

If you have any doubts that your OsCommerce security has been compromised PLEASE follow these steps:

  1. CHECK if you have any .php files in the images directory. By default OsCommerce does not store any .php files there.
  2. Check for suspicious admin users. This can be done by logging in your OsCommerce admin backend and choosing the option 'Administrators' from the Configuration menu. By default there is only one administrator.
  3. Download all your files and SCAN them with an antivirus software. This can help find some POPULAR exploits but not all.

If you have any doubts that your OsCommerce security has been compromised please follow these steps:

18.

How To Secure Oscommerce?

Answer»

In order to secure OsCommerce please follow these steps:

  1. Download all your OsCommerce files
  2. Create a backup in case something goes wrong later
  3. Scan all the files with an antivirus SOFTWARE and delete the suspicious ones
  4. Check manually for suspicious code in your files. If you have doubts about parts of the code, check the original OsCommerce files
  5. Make sure there are no .php (.pl, .cgi) files in your images directory. Executable files are not supposed to be there under any circumstances.
  6. Once you perform the above steps upload your files to your webserver.
  7. Make sure that your installation is the LATEST OsCommerce version. If not, upgrade it following the official instructions
  8. PASSWORD PROTECT your admin directory additionally or limit its access by IP
  9. Disable the following functions in PHP:

    disable_functions =exec,passthru,shell_exec,proc_open,popen,curl_exec,curl_multi_exec
    Besides that, make sure that register_globals and allow_url_include are turned off.

  10. Depending on your host and webserver try to FIND additional protection in mod_security rules or suhosin rules applicable to OsCommerce.

In order to secure OsCommerce please follow these steps:

19.

How To Setup Oscommerce To Use Smtp?

Answer»

osCommerce COULD be setup to use the SMTP functionality inside its back-end, but there are some manual modifications needed in order to fully setup the SMTP functionality of this application.

Follow these steps to complete the setup:

  • Access the osCommerce administrative panel. The URL should be similar to http://yourdomain.com/admin.
  • Go to Configuration > Email OPTIONS.
  • CHOOSE "SMTP" as the Transport METHOD.

osCommerce could be setup to use the SMTP functionality inside its back-end, but there are some manual modifications needed in order to fully setup the SMTP functionality of this application.

Follow these steps to complete the setup:

20.

In The Class Method I.e Set_extensions($extensions), $extensions Can Either Be A String Containing One Extension Type, Or An Array Containing Many Extension Types?

Answer»

YES, In the CLASS METHOD i.e set_extensions($extensions), $extensions can either be a string containing one extension type, or an ARRAY containing many extension types.

Yes, In the class method i.e set_extensions($extensions), $extensions can either be a string containing one extension type, or an array containing many extension types.

21.

Which Class Property Is An Array Containing One Or More Allowable File Upload Types?

Answer»

$extensions class property is an array CONTAINING ONE or more ALLOWABLE file upload types.

$extensions class property is an array containing one or more allowable file upload types.

22.

By Default, Oscommerce Saves All Uploaded Image Files To The Images Folder?

Answer»

YESBy default, OSCOMMERCE SAVES all UPLOADED image files to the images folder.

Yes, By default, osCommerce saves all uploaded image files to the images folder.

23.

Html Text Has Priority Over An Image For The Banner?

Answer»

YESHTML TEXT has priority over an image for the BANNER.

yes, HTML Text has priority over an image for the banner.