With your hosting account as Web Hosting Hub, you can install PEAR modules through your cPanel.  As this is an advanced web hosting tool we are not able to provide technical support on PEAR modules, however we do provide a guide to assist you in installing a PEAR module.

Custom Installation of a PEAR Module

1. Create a directory outside your public_html called "pear." This folder will require permissions of 777. Then, create another folder in your public_html.  For purposes of this examples, the folder we are creating is called "pear-examp"

2. Go to http://pear.php.net/go-pear and copy the contents of that page into a Notepad file called "go-pear.php" and upload this file into pear-examp

3. In your browser, go to http://yourdomain.com/pear-examp/go-pear.php. From here, the only field you should need to edit is the installation prefix, which will be the absolute path to the 'pear' directory that you created: /home/username/pear (with username being your Web Hosting Hub username)

You will also want to set the php CLI path in question 11. The path to the php binary is /usr/bin/php.

4. Once the installation is complete, Pear has been installed on your site. You will need to make sure to set the include path in your scripts to show the same path as your installation, and not the one on the server:

set_include_path('../../pear/PEAR' . PATH_SEPARATOR . get_include_path()); 

5. From here you can also install your own pear packages. To do this, you can create a file called "install.php" in your pear-examp directory and add this code:

include_once "../../pear/index.php"; 

When you load this page in a browser (http://yourdomain.com/pear-examp/install.php) you will see the PEAR installation interface, where you can install your own PEAR modules.

Did you find this article helpful?

Login to comment.

Your Opinion Matters

... but we need to know what you're thinking!

The Community Support team wrote the article you're looking at now. We like to think it's perfect, but we're sure you have some suggestions. Please, let us know what they are!

Feedback
Your Email Address
Because we'd like to talk with you!

Support Center Search

Current Customers

Email: support@WebHostingHub.com Ticket: Submit a Support Ticket
Call: 877-595-4HUB (4482)
757-416-6627 (Intl.)
Chat: Click To Chat Now

Ask the Community

Get help with your questions from our community of like-minded hosting users and Web Hosting Hub Staff.

Not a Customer?

Get web hosting from a company that is here to help.