"; echo mysql_error(); } else{ $data = mysql_fetch_array($res); if(mysql_num_rows($res)==0){ # If the link has never been clicked, put a new entry in there $sql = "insert into link (pageReferer,linkName,counter) values ('$pageReferer ','$linkName','1')"; } else { # Update the counter for that link entry $sql = "update link set counter=counter+1 where id='".$data['id']."'"; } } $res = mysql_query($sql); if(!$res){ echo "Database must not be on!!
"; echo mysql_error(); } else { mysql_free_result($res); Header("HTTP/1.0 302 Redirect"); Header("Location: $linkName"); } */ ?> OttawaKiosk Links