Problem with PHP OptionsConnector and DHTMLX 4.0

PHP Code

When I run this code all I get back is the main select statement.

I have downloaded the latest PHP connector but the set_options code is not returning any paired data. If I comment out set_options I get the same data returned.

require_once(“…/codebase/connector/options_connector.php”);// includes the appropriate connector
require_once(“…/codebase/connector/grid_connector.php”);//includes related connector file

$dbConn=mysql_connect(“host”,“username”,“password”);//connects to server containing the desired DB

$staffGrid = new GridConnector($dbConn,“MySQL”); // connector initialization
$staffGrid->enable_log(“STAFF.LOG”, false);

$location = new OptionsConnector($dbConn,“MySQL”);
$location->render_sql(“SELECT ID as value, LOCATION as label from tblLocations”,“ID”,“ID(value),LOCATION(label)”);



LOG File

Log started, 31/08/2014 09:08:28


Done in 0.002000093460083s

Log started, 31/08/2014 09:11:04


Done in 0.003000020980835s

Log started, 31/08/2014 09:11:05


Done in 0.00099992752075195s

Returned XML

[code]This XML file does not appear to have any style information associated with it. The document tree is shown below.


When I try the sample that come with the PHP Connector package from GitHub. I keep receiving

Error Type: LoadXML
Description: Incorrect XML


Found the issue.

I needed to include the connector.js to display the correct info in the grid instead of just the value.

If you are just calling the php script, it will really show only the main select query.

Grid component, adds extra parameters to the URL when it need data for the select filters or combo columns. Without such extra parameters server side code will not use “options” collections.

Please be sure that you have a combo or select filter for the related column in the grid. And that you have included connector.js on the page ( if you are using dhtmlx 4.0.3 and single dhtmlx.js file - there is no need to include connector.js )


I believe I was using 4.0.2 pro. I have now upgraded to 4.0.3 pro.

Is there a .chm file of your documentation or a PDF of the API calls ?

I have used 4.0.3 and I still needed to include connector.js

ReadMe File of Zip

[code]dhtmlxSuite v.4.0.3 Professional edition

© Dinamenta, UAB.[/code]

Strange, it works fine for me.
I will double-check the package structure.
If you have some kind of demo where it can be checked - please PM me, or open ticket in the support system.

same behavior here
I have 4.0.3 pro and I need to include connector.js even if I am using the full dhtml.js file

with 4.1.3 this has been solved, with full dhtmlx.js, connector.js must not be included anymore