" . substr($x, 0, strlen($var)) . "" . substr($x, strlen($var), strlen($x) - strlen($var)); else return $x; } function getTaxonList($query) { $max_rows = 50; $p = $query->getParam(0); $pat = ucfirst($p->scalarval()); $p = $query->getParam(1); $table = str_replace('field_', 'suggest', $p->scalarval()); $sql = "select Name, unitCount from $table where Name LIKE '$pat%' LIMIT ".$max_rows; mysql_connect('192.168.2.10', 'webuser' , ''); mysql_select_db('syn_europe'); //mysql_connect('192.168.2.251', 'WebUser' , ''); //mysql_select_db('synthesys'); $result = mysql_query($sql); $s = ""; $i = 0; while ( ($row = mysql_fetch_array($result))) { $s .= "