ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Error loading after PHP upgrade
Posted by Alex on Jul-26-2012 07:40
Hi there,

I had running ChartDirector perfectly before my hosting service changed to PHP5. Now i
am receiving the following error even when i uploaded the CharDirector files for PHP5.

Error Loading ChartDirector for PHP Extension

It appears this PHP system has not loaded the ChartDirector extension by using an
extension statement in the PHP configuration file (typically called "php.ini"). An attempt
has been made to dynamically load ChartDirector on the fly, but it was not successful.
Please refer to the Installation section of the ChartDirector for PHP documentation on
how to resolve this problem.

Error Log

The version and type of PHP in this system does not support dynmaic loading of PHP
extensions. All PHP extensions must be loaded by using extension statements in the PHP
configuration file.

System Information
Operating System : Linux cl29 3.2.6mtv10 #1 SMP Wed Apr 4 09:28:15 PDT 2012 x86_64
PHP version : 5.3.10
PHP / Web Server interface : cgi-fcgi
PHP configuration file location : "/nfs/c01/h09/mnt/32023/etc/php.ini"
PHP extension directory : "./" (note: directory ambiguous)

In the server enable_dl is set to ON and safe_mode is set to off

Any clue?

Thanks!

  Re: Error loading after PHP upgrade
Posted by Peter Kwan on Jul-26-2012 15:29
Hi Alex,

Since PHP 5.3, PHP no longer support dynamic loading of PHP extensions for web server usage (that is, the "dl" function is completely removed). See:

http://www.php.net/dl

So the only method to load extension now is to use extension statements in "php.ini".

Due to the above PHP limitation, many hosting providers nowadays support custom "php.ini". It means each user can configure his own "php.ini". In a typical case, the user can just put "php.ini" in the root web document directory, or in the same directory as the PHP script. The exact details differ depending on your hosting company. Some hosting companies require the "php.ini" to be renamed to something else and be put in a special directory.

For your case, I am not sure if "/nfs/c01/h09/mnt/32023/etc/php.ini" is your custom "php.ini", or is a system directory. In any case, you can check with your hosting provider or go to their support forums to see if custom "php.ini" is supported. You can also try to perform some experiments (by putting "php.ini" in your own directory) to see if custom "php.ini" is supported. If custom "php.ini" is supported, and you do have a custom "php.ini" file, the phpinfo should list that the actual "php.ini" loaded is your custom "php.ini". In this case, you can use "extension_dir" to set the PHP extension directory to your own directory, and use "extension=phpchartdir530.dll" to load the ChartDirector for PHP extension.

Even if custom "php.ini" is not supported, if your server supports CGI (cgi-bin), it is usually possible to launch your own private copy of PHP (with requiring any administrative privilege on your part), in which you have full control. See method (3) in the following thread:

http://www.chartdir.com/forum/download_thread.php?bn=chartdir_support&thread=1314232836#N1314254282

Hope this can help.

Regards
Peter Kwan