PHP beginner |
|
Ziet iemand hier een fout want ik kan hem maar niet vinden
<?php
include("config.php");
include('maak_nav.php');
$sql2 = "SELECT * FROM gastenboek_leden WHERE gastenboek_naam = '".mysql_real_escape_string($_GET['gb'])."'";
$query2 = mysql_query($sql2)or die(mysql_error());
while($fetch = mysql_fetch_assoc($query2)){
$kleur = htmlspecialchars($fetch['kleur']);
}
$tot = $aantal_per_pagina;
$sql = "SELECT * FROM gastenboek WHERE gastenboek_naam = '".mysql_real_escape_string($_GET['gb'])."'";
$query = mysql_query($sql)or die(mysql_error());
$num = mysql_num_rows($query);
$nav = new pagenav($num, $tot, $_GET['nav'], "gb=".$_GET['gb']."&PageID=1");
$van = $nav->get_startpoint();
$sql = "SELECT * FROM gastenboek WHERE gastenboek_naam = '".mysql_real_escape_string($_GET['gb'])."' LIMIT $van, $tot";
$query3 = mysql_query($sql)or die(mysql_error());
$num2 = mysql_num_rows($query3);
?>
<?php include("config.php"); include('maak_nav.php'); } $tot = $aantal_per_pagina; $nav = new pagenav($num, $tot, $_GET['nav'], "gb=".$_GET['gb']."&PageID=1"); $van = $nav->get_startpoint(); ?>
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
|