Using PHP

switching to php 5.3

Check out this guide on how to upgrade from PHP 5.2 to PHP 5.3: http://www.webenabled.com/kb/node/20

Enabling IonCube Loader

Following is a howto article for enabling IonCube. This PHP module is not enabled by default. Substitute w_USER for the appropriate web username. 1. Created a local version of php-cgi-fcgi.ini using the following command. $ cp /opt/php/config/php-cgi-fcgi.ini ~w_USER/public_html/USER/ 2.Added the following line to the beginning of ~w_USER/public_...

PHP Warning: get_headers() [<a href='function.get-headers'>function.get-headers</a>]: This function may only be used against URLs.

Add the following setting to ~/.php/php.ini allow_url_fopen = On; This will fix the above mentioned error. This setting is disabled by default to enhance security.

How do I enable error messages so they display in the browser?

If you are having trouble getting error messages to display in your browser then you should edit your local php.ini with the following directives. The local php.ini is located at ~/.php/php.ini. $ vi ~/.php/php.ini Then add the following lines: error_reporting = E_ALL display_errors = 1 display_startup_errors = 1 You may learn more about the PH...

Pear/PECL Usage

WebEnabled has developed a wrapper for Pear/PECL so that each application can have its own install base of PHP Pear/PECL packages. Usage is simple. $ pecl install uploadprogress That's it! This will install the uploadprogress module to your application.

Enabling ZendOptimization, APC or eAccelerator

Following are the instructions for enabling any of the PHP caching mechanisms to performance boost your site. APC To enable APC the following changes should be made, add the following lines to ~/.php/php.ini:

Custom PHP settings file

For any given application you may edit ~/.php/php.ini. ~/.php/php.ini is read by PHP every time PHP is run (a PHP script is accessed on the Web). We use CGI with a standalone PHP for running PHP scripts, so there is no need to restart Apache to activate new settings. Another important note is that if your application is running under FastCGI (our s...