Product Documentation

V11.5 Update Guide

Previous Topic

Next Topic

c-treeACE PHP 7 Support

FairCom introduces support for the PHP Data Objects extension to the scripting language that drives the Internet.

PHP (Hypertext PreProcessor) is a widely-used scripting language that is especially suited for creating data-driven websites.

c-treePHP Diagram

Originally, PHP used conventional SQL to access a database to retrieve data. Developers have long recognized one drawback: many databases use variations of "standard" SQL, making it difficult to migrate between different database providers.

PHP Data Objects (PDO) Extension

To address this issue, the community that develops PHP introduced the PHP Data Objects (PDO) extension for accessing a database. PDO gives you an abstraction layer so that your applications use the same functions to issue queries regardless of the underlying database. PDO allows an application to be independent of its database, so a developer can change databases without changing the application logic.

c-treeACE PHP offers native support for this extension by including a database-specific PDO driver to access the FairCom Server.

  • Developers who are interested in taking advantage of this interface for accessing the c-treeACE database using the latest PHP standard will want to use this interface.
  • Developers who have an existing PHP application that uses PDO are able to upgrade their application to use c-treeACE by simply installing the driver—no re-coding should be required.

c-treeACE provides two versions of the c-treeACE PHP drivers:

  • sql.php.pdo - Support for PHP 7 and the PDO extension. This is the preferred way to access c-treeACE from PHP. An example showing the usage of this new support is included in the \FairCom\V*\<your platform>\sdk\sql.php.pdo directory. See the ReadMe located in that directory.
  • sql.php - Support for PHP 4, PHP 5, and PHP 7.

TOCIndex