1

我收到语法错误,$q 行出现意外 $q ..

<?php
$sql = "SELECT title FROM `PREFIX_GOOGLEMAPZZZ_markers`"
$q = mysql_query($sql)
echo "<select name=\"title\">";
echo "<option size =30 ></option>";
while ($row = mysql_fetch_array($q)) {
echo "<option value='" . $row['title'] . "'>" . $row['title'] . "</option>";
}
echo "</select>";
?>
4

1 回答 1

1

您在这些行的末尾缺少分号。

 $sql = "SELECT title FROM `PREFIX_GOOGLEMAPZZZ_markers`";
 $q = mysql_query($sql);
于 2012-11-02T15:03:16.500 回答