Hi,
I'm modifying a page to not only display the amount of sign ups for a meeting but also the amount of people that are coming to the meeting. The code normally works but on this page i have to retrieve the date to count the amount of people coming. Anybody know what im doing wrong?
thanks
<?php
$colname_rs_backpack = "1";
if (isset($HTTP_GET_VARS['datum'])) {
$colname_rs_backpack = (get_magic_quotes_gpc()) ? $HTTP_GET_VARS['datum'] : addslashes($HTTP_GET_VARS['datum']);
}
mysql_select_db($database_backpack, $backpack);
$query_rs_backpack = sprintf("SELECT * FROM bijeenkomst WHERE datum = '%s' AND verwijder='n' ORDER BY aanvraagnr ASC", $colname_rs_backpack);
$rs_backpack = mysql_query($query_rs_backpack, $backpack) or die(mysql_error());
$row_rs_backpack = mysql_fetch_assoc($rs_backpack);
$totalRows_rs_backpack = mysql_num_rows($rs_backpack);
//this code works
?>
<?php
$query = "select sum(partysize) from bijeenkomst WHERE datum = '%s' AND verwijder = 'n'";
$result = mysql_query($query, $backpack);
$row = mysql_fetch_row($result);
//this is the piece of code that doesnt work and counts the number of people
?>