View Full Version : How to include additional PHP files
I am wondering how to include a PHP file in a Lianja webview. I would normally type the line include "myfile.php";. Where do I store such a file and how do I access it within Lianja?
davefoss
2013-10-03, 14:31
I am wondering how to include a PHP file in a Lianja webview. I would normally type the line include "myfile.php";. Where do I store such a file and how do I access it within Lianja?
If you only need the file to be available to a particular app then open that app and add the file via the Apps Workspace. If you want it available to multiple apps then put it in the Lianja Library (via the Library Workspace).
barrymavin
2013-10-03, 22:47
Lianja includes PHP, Python and JavaScript as part of the distribution as these are embedded in the App Builder.
PHP is located in:
C:\lianja\scriptinglanguages\php
The PHP configuration file is located in:
C:\lianja\scriptinglanguages\php\conf\php.ini
You can also set the include_path in php.ini. It is currently commented out and defaults to the current app directory. You can therefore reference php libraries relative to the app like this:
include("..\libraries\myphplib.php")