dice : T_CONSTANT_ENCAPSED_STRING
te pongo todo el codigo
Código PHP:
<?php
$db = new mysqli('host', 'userl' ,'pass', 'd_B');
if(!$db) {
echo 'ERROR: Could not connect to the database.';
} else {
if(isset($_POST['queryString'])) {
$queryString = $db->real_escape_string($_POST['queryString']);
if(strlen($queryString) >0) {
$query = $db->query("SELECT * FROM palabras WHERE CONCAT( valores, " ", w1, " ", w2) LIKE '$queryString%' LIMIT 10");
if($query) {
while ($result = $query ->fetch_object()) {
echo '<li onClick="fill(\''.htmlentities($result->valores).'\');">'.htmlentities($result->valores).'</li>';
}
} else {
echo 'ERROR: There was a problem with the query.';
}
} else {
}
} else {
echo 'There should be no direct access to this script!';
}
}
?>