[Script] Loterij Script

Gestart doorMarv19 reacties37 weergaven

20 berichten · pagina 2 van 2

Berichten
3.112
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Vriendje schreef:
Eerdere citaten tonen
Gamedealer schreef:
Eerdere citaten tonen
Vriendje schreef:
Dan moet die persoon op dat moment pagina bezoeken, of je hebt cron nodig die elke minuut uitgevoerd word en wat ik me nu tikdens het typen dus pas bedenk xd
Ook niet. Je denkt veel te moeilijk.
Eerdere citaten tonen
Efferinie schreef:
Ik ben nog niet voorzien en zou het graag zondag/maandag af willen hebben.

Bij Belangstelling: PM even!

Zal even kijken of dat mogelijk is i.v.m. ander werk.
Hoe dan weeeelll...?
Dat zoek je zelf maar uit dan, anders geef ik mijn eventuele opdracht wegclown
0
Berichten
414
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?

$dag[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/date"]date[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]d-m-y[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$select1[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]"SELECT * FROM loterij WHERE dag=$dag ORDER BY RAND() LIMIT 1"[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$query1[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$select1[/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/while"]while[/URL] [COLOR= #007700]([/COLOR][COLOR= #0000BB]$lijst1[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_object"]mysql_fetch_object[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query1[/COLOR][COLOR= #007700])) {[/COLOR]

[COLOR= #0000BB]$select2[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]"SELECT * FROM loterij WHERE id=$lijst1->stemid LIMIT 1"[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$query2[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$select2[/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/while"]while[/URL] [COLOR= #007700]([/COLOR][COLOR= #0000BB]$lijst[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_object"]mysql_fetch_object[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query2[/COLOR][COLOR= #007700])) {[/COLOR]

[COLOR= #0000BB]$query1[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"UPDATE loterij SET punten=punten+5 WHERE id = $lijst->id"[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$result1[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query1[/COLOR][COLOR= #007700]);[/COLOR]

[COLOR= #0000BB]$dag[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/date"]date[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]d-m-y[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$query[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"UPDATE loterij SET winnaar=Ja WHERE stemid = $lijst->id AND dag=$dag"[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$result[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700]);[/COLOR]

[URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]"Winnaar is $lijst->naam"[/COLOR][COLOR= #007700];[/COLOR]

[URL="http://www.php.net/mail"]mail[/URL] [COLOR= #007700]([/COLOR][COLOR= #DD0000]"$lijst->email"[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]"Winnaar Loterij "[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]"Beste $lijstt->naam,

Gefeliciteerd jij hebt vandaag de loterij gewonnen, er zijn 5 punten aan je account toegevoegd!

Met vriendelijke groet,

Voornaam Achternaam
Websitenaam.nl"[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]"From: Websitenaam.nl<info@websitenaam.nl>"[/COLOR][COLOR= #007700]);
}
}[/COLOR]
?>


Zo iets bedoelje? Dit heb ik van internet alleen beetje bewerkt...
0
Berichten
8.649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Dan gebeurt het niet Op gewild tijdstip en moet er minimum 1 bezoeker zijn geweest op de dag van de trekking.
0
Marv

Lid · Topicstarter

Berichten
3.092
Reputatie
1
Punten
0,21
Lid sinds
Laatst gezien
----
0
Marv

Lid · Topicstarter

Berichten
3.092
Reputatie
1
Punten
0,21
Lid sinds
Laatst gezien
BUMP
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