Hello,
I’m trying your samples to populate a combobox from a mysql table, just adapted to my database.
Nothing is working, what I’m doing wrong ?
Here is the code :
basic_connector.php
Dwh_Unimag : database
Structure : table
[code]
<?php $res=mysql_connect("10.xx.yy.zz","root","mypassword"); mysql_select_db("Dwh_Unimag"); require("codebase/combo_connector.php"); $combo = new ComboConnector($res); $combo->render_table("Structure","id_structure","nom"); ?>[/code]basic.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Test Combobox</title>
<script>
window.dhx_globalImgPath="../dhtmlx/imgs/";
</script>
<script src="codebase/dhtmlx.js" type="text/javascript" charset="utf-8"></script>
<script src="codebase/connector.js" type="text/javascript" charset="utf-8"></script>
<link rel="stylesheet" href="codebase/dhtmlx.css" type="text/css" charset="utf-8">
</head>
<body>
<div id="combo_zone4" style="width:200px; height:30px;"></div>
<hr/>
<div id="combo_zone5" style="width:200px; height:30px;"></div>
<hr/>
<script>
var z=new dhtmlXCombo("combo_zone4","alfa4",200);
z.loadXML("basic_connector.php");
</script>
<script>
var z=new dhtmlXCombo("combo_zone5","alfa4",200);
z.enableFilteringMode(true,"basic_connector.php",true);
</script>
</body>
</html>
I need your help, I don’t understand my mistake.
Regards