I was messing around with the output echo that gave the results of the query trying to figure out how to make the dog breed bold and now I am getting this
-Parse error: parse error in /Library/WebServer/Documents/dogs.php on line 22
I am pulling my hair out on this, if anyone can help with either the parse error or how to make the dog breeds bold I would be in your debt.
$conn = new mysqli($servername, $username, $password, $dbname);
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
$sql = "SELECT b.dogbreed ,(SELECT GROUP_CONCAT(DogName) FROM Names WHERE dogId=b.dogId ) as Dognames from breeds b";
$result = $conn->query($sql);
if ($result->num_rows > 0) {
while($row = $result->fetch_assoc()) {
echo . $row["dogbreed"]. " - " . $row["Dognames"]. "<br>";
}
} else {
echo "0 results";
}
$conn->close();
?>
</html>
";` – RiggsFolly Apr 29 '17 at 00:45