Ik heb op me projectje een kerstspecial in een scriptje gemaakt
maar hij doet het niet, ik kan niet ontdekken waarom
wat is hier fout aan?:
Alvast bedankt!
maar hij doet het niet, ik kan niet ontdekken waarom
wat is hier fout aan?:
<div style="display: none;">
<div id="inline1" style="width:1000px;height:300px;overflow:auto;">
<center><img src="http://img824.imageshack.us/img824/3085/merrychristmasbart.png" alt="Merry Christmas!" /><br />
Welkom bij de kerst special!<br />
Bij de kerst special krijgt u 2 punten helemaal gratis van ons!<br />
Klik op de knop om de punten in ontvangst te nemen.<br />
<input type="submit" name="kd" value="Ontvang Cadeau" /><br />
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]kd[/COLOR][COLOR= #007700]]))
{[/COLOR]
[COLOR= #0000BB]$arrFout[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/array"]array[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_num_rows"]mysql_num_rows[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$fQuery[/COLOR][COLOR= #007700]) !=[/COLOR] [COLOR= #0000BB]0[/COLOR][COLOR= #007700])
{[/COLOR]
[COLOR= #0000BB]$arrFout[/COLOR][COLOR= #007700][] =[/COLOR] [COLOR= #DD0000]U heeft al meegedaan aan de Kerst Special[/COLOR][COLOR= #007700];
}[/COLOR]
[URL="http://www.php.net/else"]else[/URL]
[COLOR= #007700]{[/COLOR]
[COLOR= #0000BB]$cadeau[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]2[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"UPDATE leden SET uPunten = uPunten +"[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$cadeau[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]" WHERE uId = "[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]uId[/COLOR][COLOR= #007700]] .[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_error"]mysql_error[/URL][COLOR= #007700]());[/COLOR]
[URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"INSERT INTO kerst (uId) VALUES ("[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]uId[/COLOR][COLOR= #007700]] .[/COLOR] [COLOR= #DD0000]")"[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_error"]mysql_error[/URL][COLOR= #007700]());
}[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700](![/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$arrFout[/COLOR][COLOR= #007700]))
{[/COLOR]
[URL="http://www.php.net/foreach"]foreach[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$arrFout[/COLOR] [COLOR= #007700]as[/COLOR] [COLOR= #0000BB]$val[/COLOR][COLOR= #007700])
{[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$val[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]<br />[/COLOR][COLOR= #007700];
}
}[/COLOR]
[URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$arrFout[/COLOR][COLOR= #007700]))
{[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]De punten zijn overgeschreven[/COLOR][COLOR= #007700];
}
}[/COLOR]
?></center>
</div>
</div><br /> Alvast bedankt!