Niks mis mee, kijk wel liever naar PDO en vergeet de mysql_*() functies
toevoeging op 19 maart 2013, 18:52:07:
Pas foutafhandeling toe!!!!!!!!!!!!!!
toevoeging op 19 maart 2013, 18:52:07:
Janm schreef:Ik heb deze code:
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"<h1>Je hebt gestemd op deze server!</h1>"[/COLOR][COLOR= #007700];[/COLOR]
mysqli_query[COLOR= #007700]([/COLOR][COLOR= #0000BB]$con[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]"UPDATE servers set votes = votes +1 WHERE id = $serverid"[/COLOR][COLOR= #007700]);[/COLOR]
mysqli_query[COLOR= #007700]([/COLOR][COLOR= #0000BB]$con[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]"INSERT INTO votes (name, ip, date) VALUES ($mcname, $ip, $date)"[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"Je hebt succesvol gestemd op <strong>"[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$row[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]title[/COLOR][COLOR= #007700]] .[/COLOR] [COLOR= #DD0000]"</strong>"[/COLOR][COLOR= #007700];[/COLOR] Pas foutafhandeling toe!!!!!!!!!!!!!!

