X-Cart:X-Payments Subscriptions and Installments module installation
System requirements
To be able to use the X-Payments Subscriptions and Installments module, you need the following components installed and configured on your system:
- X-Cart 4.4.5-4.6.x (If you do not remember the version of X-Cart on which your store is based, you can look it up in the Environment info section of the Summary page in X-Cart Admin area);
- X-Payments 2.0.0 or later.
Subscription payments with the help of X-Cart's X-Payments Subscriptions and Installments module can be implemented only for X-Payments based payment methods that support re-use of saved credit cards via tokenization. For this reason, you must have a properly configured payment configuration in your X-Payments application for one of the payment gateways that support tokenization.
Your X-Cart installation must be connected to X-Payments using X-Cart’s built-in X-Payments Connector module, and you must have an X-Payments based payment method in X-Cart configured for use with saved credit cards (For instructions on configuring such a paymet method in X-Cart, see the section Enabling Payments with Saved Credit Cards).
You will find that the X-Payments Subscriptions and Installments module archive contains a script "xps_cron.php" (for X-Cart versions 4.6.1 and earlier - "cron_subscriptions.php"). After installing the module, you will need to configure your server to run this script automatically on a schedule. See Running the script xps_cron.php for instructions.
Installation
Starting with X-Cart 4.6.2, the X-Payments Subscriptions and Installments module is available as a built-in module in all X-Cart editions. It does not require installation and can be enabled in the X-Cart Admin area. For X-Cart versions 4.4.5-4.6.1, this module can be purchased and installed separately.
Following are the instructions for installing the X-Payments Subscriptions and Installments module on X-Cart versions 4.4.5-4.6.1.
To install the module:
- From the File Area section of your X-Cart Account, download the archive xpayments_subscriptions.tgz (or xpayments_subscriptions.zip). In this archive you will find all the module versions that are currently available. Archives for specific versions will have names like xpayments_subscriptions-x.y.z.tgz, where the numbers x, y and z designate the version of X-Cart for which the module archive is intended.
- Copy the contents of the module achive for your specific X-Cart version to the X-Cart root directory on your server or hosting account.
- If you are using a Windows-based server, or a UNIX-based server without terminal access:
- a) Unpack the module archive to a directory on your system using your favorite compression program (WinZIP, 7-Zip or any other archiver with support for TAR files).
- b) Use an FTP client to upload all the files contained in this directory (retaining the directory structure) to the X-Cart root directory on your server or your hosting account.
- If you are using a UNIX-based server with terminal access:
- a) Use an FTP client to upload the module archive to the X-Cart root directory on your server or your hosting account.
- b) Unpack the archive using the following command:
tar -xzvf xpayments_subscriptions-x.y.z.tgz
- (Replace x, y and z with the actual version numbers).
- Important: Make sure you keep the directory structure while unpacking and uploading the module archive, otherwise some necessary files may be overwritten!
- In a web browser, run the installation script httр://<YOUR_XCART_DOMAIN>/install-xpayments_subscriptions.php replacing <YOUR_XCART_DOMAIN> with the actual domain name of your X-Cart store. This will start the installation wizard. A screen like the following will be displayed:
- Carefully read the License agreement, enter the Auth code for your X-Cart installation into the Auth code field and select the "I accept the License Agreement" check box:
- Click Next to continue. The installation process will start. The installer will make the necessary changes to your X-Cart installation, and the module will be activated:Note: If you are using a custom skin, you will need to patch it manually. Otherwise, the module will not work in this skin.
- Once the process is completed, click Next. This will open the next screen where you will be asked whether you wish a new system fingerprint to be generated:
- Make your selection (Yes/No) and click Next. If you have chosen to generate a new system fingerprint, it will be generated. The process of generating a system fingerprint may take up as long as a few minutes. Once the generation process is completed, click Next. If you have chosen to skip the generation of a system fingerprint, you will be taken to the next step.
- After clicking Next you should see the "Installation complete" screen:
This is the final step. It informs you that the module has been installed successfully. It also reminds you to remove the module archive file in case you put it in a web accessible directory; this is needed to protect the module from unauthorized copying.
Important: At the final step of the installation process, the installation script install-xpayments_subscriptions.php is automatically renamed as an additional measure to protect the module installation. Please take note of the filename to which the installation script was renamed. If you decide to re-install or uninstall the module later on, you will need to rename the installation script back to install-xpayments_subscriptions.php before launching the installation process in your web browser.
Now if you choose to view the list of your store's installed modules (this can be done using the Administrator area link provided on the "Installation complete" screen), the X-Payments Subscriptions and Installments module will be on the list:
Note that after the module has been installed, it is already in the enabled (active) state. You can temporarily disable the module using the module deactivation instructions from the section Activating and deactivating the module.
See also:
Uninstallation
Uninstallation completely removes all the data related to X-Payments Subscriptions and Installments module from your store.
To complete the uninstallation, you will need to run the X-Payments Subscriptions and Installments module installation script. You might remember that, after the module was installed in your store, the script was saved with a new name to help prevent unauthorised runs of the installer. Now, before you start, you need to rename the script back to its original name - install-xpayments_subscriptions.php.
To uninstall the module:
- Run the module installation script in your web browser by going to httр://<YOUR_XCART_DOMAIN>/install-xpayments_subscriptions.php (be sure to replace the <YOUR_XCART_DOMAIN> part with the actual domain name of your X-Cart store). This will start the installation wizard. A screen like the following will be displayed:
- Select "Uninstall the module", enter the Auth code for your X-Cart installation into the Auth code field and select the "I accept the License Agreement" check box:
- Click Next to continue. The uninstallation process will start. The installer will make the necessary changes to your X-Cart installation, and the module will be deactivated.
- Once the process is completed, click Next. This will open the next screen where you will be able to generate a new system fingerprint.
- Generate the system fingerprint (or skip it). After clicking Next you should see the "Uninstallation complete" screen.
This is all. The X-Payments Subscriptions and Installments module has been uninstalled.