Mennos probleem

Gestart doorAugust11 reacties38 weergaven

12 berichten · pagina 1 van 1

August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Ik heb in instellingen.php ingesteld dat als je inlogt dat je dan 2 muntjes krijgt, maar als ik inlog krijg ik 300 muntjes? emo Dat is ingesteld door mennos, hoe verhelp ik het?
0
Berichten
3.461
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
post instellingen.php eens! smile
0
Berichten
1.641
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
inderdaad, mischien dat het systeem het omrekend.
0
August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Oeps, zat niet in instellingen.php, maar hier is de code:

[COLOR= #0000BB]<?php

$aantal[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700];[/COLOR] [COLOR= #FF8000]// aantal muntjes dat erbij komt[/COLOR]
[COLOR= #0000BB]$aantalclublid[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700];[/COLOR] [COLOR= #FF8000]// aantal muntjes dat erbij komt als je clublid bent[/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]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]])) {[/COLOR]
    [COLOR= #0000BB]$dag[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/date"]date[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"Y-m-d"[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"INSERT INTO muntjesperdag (member_id,dag) VALUES ("[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]].[/COLOR][COLOR= #DD0000]",NOW())"[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_error"]mysql_error[/URL][COLOR= #007700]() !=[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]) {[/COLOR]
        [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"Je hebt vandaag al je muntjes gehad, je moet wachten tot morgen."[/COLOR][COLOR= #007700];
    }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
        [COLOR= #0000BB]$sql_club[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT * FROM clublid WHERE member_id="[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]].[/COLOR][COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
        [COLOR= #0000BB]$row_club[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_assoc"]mysql_fetch_assoc[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$sql_club[/COLOR][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]$sql_club[/COLOR][COLOR= #007700]) ==[/COLOR] [COLOR= #0000BB]1[/COLOR][COLOR= #007700]) {[/COLOR]
            [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"UPDATE leden SET muntjes=muntjes+"[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$aantal[/COLOR][COLOR= #007700].[/COLOR][COLOR= #DD0000]" WHERE member_id="[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]].[/COLOR][COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
            [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"Je hebt "[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$aantalclublid[/COLOR][COLOR= #007700].[/COLOR][COLOR= #DD0000]" muntjes erbij gekregen."[/COLOR][COLOR= #007700];
        }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
            [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"UPDATE leden SET muntjes=muntjes+"[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$aantalclublid[/COLOR][COLOR= #007700].[/COLOR][COLOR= #DD0000]" WHERE member_id="[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]].[/COLOR][COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
            [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"Je hebt "[/COLOR][COLOR= #007700].[/COLOR][COLOR= #0000BB]$aantalclublid[/COLOR][COLOR= #007700].[/COLOR][COLOR= #DD0000]" muntjes erbij gekregen."[/COLOR][COLOR= #007700];
        }
    }
}[/COLOR]

?>
0
Berichten
3.461
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Verander clublid eens naar 0, en kijk wat ie dan doet! smile
0
August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Alleen clublid?
0
August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Vaag, ik ging terug met de backknop van mn browser en toen stond dit bericht er opeens 2x?

Nouja, dat van clublid werkt niet..
0
Berichten
3.461
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Okee, heb je niet een apart script wat ie aanroept om de punten te geven?
0
August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Nee dat is alles.
0
Berichten
3.461
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Okee, raar... Dan kan ik je helaas niet verder helpen, ben helaas niet zon ster in PHP! emo
0
August

Lid · Topicstarter

Berichten
7.179
Reputatie
1
Punten
3,01
Lid sinds
Laatst gezien
Oke, toch bedankt voor alle hulp die je hebt gegeven.
0
Berichten
3.461
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Geen probleem, succes met het vinden van een oplossing!
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren