If you needed IonCube for your cPanel/WHM scripts or your Apache/PHP scripts. It's straightforward to figure out: if you want to use IonCube for a script on your website, you'll have to install IonCube for your Apache/PHP installation. Install IonCube for cPanel/WHM/Webmail if you want to use IonCube to access scripts via the /cpanel, /whm, or /webmail interface. The instructions for both are provided below.

Installing IonCube for cPanel/WHM/Webmail

Below are descriptions of both the GUI and CLI techniques.

Installing via the WHM

You'll require administrative rights, normally the root password, to do this.

  1. Log into the WHM by going to your servers IP followed by /whm or :2087 (ex: http://127.0.0.1:2087/)
  2. On the left hand side click the 'Tweak Settings' link
  3. Click the PHP tab on the right hand side
  4. Find the configurable option labeled 'cPanel PHP loader' and check the ioncube checkbox
  5. Click Save

Installing via the CLI

You'll need root privileges on the server to accomplish this task.

  1. Log into the shell as the user root
  2. Edit /etc/cpanel/cpanel.config and find the line that starts with phploader=. If there is no value after the equal sign then you can simply append ioncube to it (ex: phploader=ioncube). If there is another loader already in place you can add your new loader by adding a comma first and then adding your loader (ex: phploader=someloader,ioncube)
  3. Next execute the following command, /usr/local/cpanel/whostmgr/bin/whostmgr2 –updatetweaksettings
  4. And then /usr/local/cpanel/bin/checkphpini
  5. and finally /usr/local/cpanel/bin/install_php_inis

Installing IonCube Loader for Apache/PHP

This can be achieved in a number of ways, and all are detailed below.

Installing IonCube using the CLI version of PHPExtensionManager

This is the recommended way because it only installs the loaders and does not require rebuilding Apache and PHP. Because of this, it is also the quickest way. This method requires shell access to the server as the user root, which can be done via the console, SSH, or another way.

  1. Log into the console as root
  2. Run /scripts/phpextensionmgr install IonCubeLoader

That's it! That was pretty simple, eh?!

Installing IonCube using the WHM

This method uses the GUI version of easyapache to install the ioncube loader, if you do not want to rebuild Apache and PHP then dont use this method.

  1. Log into the WHM as the user root.
  2. On the left hand side scroll down and click the EasyApache link
  3. Under 'Profile', select 'Previous Saved Config' and click the 'Start customizing based on profile' button.
  4. Under 'Apache Version' click 'Next Step'
  5. Under 'PHP Version' click 'Next Step'
  6. Under 'Short Options List' check the 'Ioncube Loader for PHP' option and click the 'Save and Build' button.
  7. This process will take a while to complete, roughly 10-30 minutes depending on your hardware.

Installing IonCube using the CLI version of EasyApache

This method requires you to have shell access as the user root via either the console, SSH or some other means.

  1. Log into the console as root
  2. Run /scripts/easyapache
  3. Select 'Previously Saved Config' and then select 'Start customizing based on profile'
  4. Under 'Apache Version' select 'Next Step'
  5. Under 'PHP Version' select 'Next Step'
  6. Under 'Short Option Lists' check the 'IonCube Loader for PHP' and then select 'Save and Build'
  7. This process will take a while to complete, roughly 10-30 minutes depending on your hardware.
Was this answer helpful? 0 Users Found This Useful (0 Votes)