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

Message ListMessage List     Post MessagePost Message

  ChartDirector Installation on CentOS7 with PHP 8.1
Posted by ruslan savitskij on Mar-01-2023 05:29
Hi,

I am trying to install on CentOS7 VPS with CWP Pro having PHP 8.1 and FPM. Kindly guide how to install if using yum would be better. I had try by placing .so file into the extension folder and enable it using php.ini but phpinfo is not displaying any details about it.

  Re: ChartDirector Installation on CentOS7 with PHP 8.1
Posted by Peter Kwan on Mar-01-2023 17:12
Hi Rusian,

First, please use phpinfo to determine your PHP type and configuration. (Simply create a PHP page that contains one line "<?php phpinfo(); ?>

Please download the ChartDirector that matches your operating system, as reported by phpinfo. For example, if it is using an Intel CPU (as opposed to ARM64), and assuming your PHP is 64-bit and your OS is Linux, please download the ChartDirector for PHP for Linux (x86_64). If you are using PHP 8.1, please download the latest version that supports up to the latest PHP version (8.2). In the "ChartDirector/lib" folder in the download, you should see a file "phpchartdir820.dll".

We suggest you copy "everything" (including the fonts folder) inside the "ChartDirector/lib" to your PHP extension directory (that path to that directory is listed in the phpinfo). If you want to copy the minimal number of files, please at least copy "phpchartdir810.*:, "libchartdir.so" and the "fonts" folder. In any case, please make sure the security settings of all the files are readable and executable by the web server. You may use the Linux command "chmod" to make them readable and executable by everyone.

Edit the active "php.ini". There can be more than one "php.ini" in your system, and the active one is the one listed in the "phpinfo". Please add the line:

# if your PHP is non-thread-safe
extension=phpchartdir810.dll

or

# if your PHP is thread safe
extension=phpchartdir810mt.dll

(Historically, some people consider thread safe PHP to be unstable, and it is offers no advantage in modern web servers which uses FastCGI or FPM. So most installation uses non-thread-safe PHP. Please check the thread-safety settings in your phpinfo.) If your system has "control panel" (like CPanel), it may have a button that allows you to restart PHP. Otherwise, you may need to start your web server (Apache?), or if FPM is used, restart your FPM service. The exact way depends on your OS. I believe in CentOS, you may use "sudo systemctl restart php-fpm" to restart the FPM service.

You can then copy the entire "ChartDirector" folder to your web document directory, and try the cdinfo.php script to see if it works.

If the above still cannot solve the problem, please check the Apache error log (or PHP error log). It should explain why the phpchartdir810.dll cannot be loaded. Please let me know what is the error message and also your phpinfo result.

Best Regards
Peter Kwan