To use the functionality of DHTMLX Connector, first you should initialize it.
Generally, both client- and server-sides are concerned in it.
1) Specify connector file in the load method of a component.
//index.html myGrid = new dhtmlXGridObject("someContainer");// initializes grid ... mygrid.load("myconnector.cfm");
1) Specify connector file in the load method of a component.
2) Initialize dhtmlxDataProcessor on the client side (read more about it here).
//index.html myGrid = new dhtmlXGridObject("someContainer");// initializes grid ... myGrid.load("my_connector.php"); myDP = new dataProcessor("myconnector.cfm");// initializes dhtmlxDataProcessor myDP.init(myGrid);
Samples Client-Side Initialization
In our examples we use mapping “dhtmlXConnectors” which links to the folder with cfc files.
Preparations:
Main steps:
<cfinclude template="../config.cfm">// connector file <cfset grid = createObject("component","dhtmlxConnectors.GridConnector").init( "#datasource#","MySQL")> <cfset grid.render_table("mytable","item_id","item_nm,item_cd")>
Back to top