Dan gebeurt er ook niks, zelfs geen error.
Kleine Vragen Topic #1
Is het niet gecommented? En mail() geeft gewoon true?
Persoonlijk vind ik dit erg vreemd, want op mijn XAMPP installatie krijg ik gewoon mails. Wel via een SMTP van mijn isp.
Hoe kan ik checken of een mail versuurd wordt? is er een error-handling voor de mail functie?
Ja, if-else... en als je meer wilt weten moet je phpMailer gebruiken.
Had ik geloof ik al verteld.
Had ik geloof ik al verteld.
Hmm.. PHPmailer werkt wel.
Moest een 2 naar een 0 zetten 
Bedankt Aarclay!

Bedankt Aarclay!
Ik heb dit als error: Parse error: syntax error, unexpected [ in /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/includes/mc/MinecraftServerStatus.class.php on line 23
Dit is de line:
het vervolgt zich met deze:
Dit is de line:
private $Info = [ het vervolgt zich met deze:
hostname => ,
gametype => ,
game_id => ,
version => ,
plugins => ,
map => ,
numplayers => ,
maxplayers => ,
hostport => ,
hostip =>
]; Dat is ook geen geldige array, wat in JS weer wel geldt.
Je werkt nu in PHP
Je werkt nu in PHP

Aarclay schreef:het is een class van het internet, ben er mee bezig geweest en alles doorgenomen, snapte wel wat alles betekende, maar krijg deze error.Dat is ook geen geldige array, wat in JS weer wel geldt.
Je werkt nu in PHP
Moet ik het zo doen:
private $Info = array(
hostname => ,
gametype => ,
game_id => ,
version => ,
plugins => ,
map => ,
numplayers => ,
maxplayers => ,
hostport => ,
hostip =>
); probeer, en je ziet.
Aarclay schreef:Krijg ik ditprobeer, en je ziet.

Fatal error: Uncaught exception Exception with message Failed to write on socket in /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/includes/mc/MinecraftServerStatus.class.php:137 Stack trace: #0 /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/includes/mc/MinecraftServerStatus.class.php(52): MinecraftServerStatus->Send(9) #1 /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/includes/header.php(7): MinecraftServerStatus->__construct(86.81.104.188:2...) #2 /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/index.php(1): include(/home/mcsl/doma...) #3 {main} thrown in /home/mcsl/domains/mcserverlijsten.nl/public_html/alpha/includes/mc/MinecraftServerStatus.class.php on line 137
dit is de line:
throw new Exception(Failed to write on socket, 2); Dan is er wat anders aan de hand, naast dat je array nu wel goed correct is.
Op welk moment van de code wordt dit ge-trowd?
Op welk moment van de code wordt dit ge-trowd?
Heb zon gevoel dit stukje:
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/private"]private[/URL] [COLOR= #007700]function[/COLOR] Send[COLOR= #007700]([/COLOR][COLOR= #0000BB]$Command[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]$Addition[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000][/COLOR][COLOR= #007700]) {[/COLOR]
[COLOR= #FF8000]// pack the command into a binary string[/COLOR]
[COLOR= #0000BB]$Command[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/pack"]pack[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]c*[/COLOR][COLOR= #007700],[/COLOR] self[COLOR= #007700]::[/COLOR]B1[COLOR= #007700],[/COLOR] self[COLOR= #007700]::[/COLOR]B2[COLOR= #007700],[/COLOR] [COLOR= #0000BB]$Command[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]0x01[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]0x02[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]0x03[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]0x04[/COLOR][COLOR= #007700]).[/COLOR][COLOR= #0000BB]$Addition[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #FF8000]// send the binary string to the server[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/strlen"]strlen[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$Command[/COLOR][COLOR= #007700]) !== @[/COLOR][URL="http://www.php.net/fwrite"]fwrite[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$this[/COLOR][COLOR= #007700]->[/COLOR]Socket[COLOR= #007700],[/COLOR] [COLOR= #0000BB]$Command[/COLOR][COLOR= #007700],[/COLOR] [URL="http://www.php.net/strlen"]strlen[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$Command[/COLOR][COLOR= #007700])))[/COLOR]
throw [COLOR= #007700]new[/COLOR] Exception[COLOR= #007700]([/COLOR][COLOR= #DD0000]Failed to write on socket[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]2[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #FF8000]// listen what the server has to say now[/COLOR]
[COLOR= #0000BB]$Data[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/fread"]fread[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$this[/COLOR][COLOR= #007700]->[/COLOR]Socket[COLOR= #007700],[/COLOR] [COLOR= #0000BB]2048[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$Data[/COLOR] [COLOR= #007700]===[/COLOR] false[COLOR= #007700])[/COLOR]
throw [COLOR= #007700]new[/COLOR] Exception[COLOR= #007700]([/COLOR][COLOR= #DD0000]Failed to read from socket[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]3[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #FF8000]// remove the first 5 unnecessary bytes (0x00, 0x01, 0x02, 0x03, 0x04) Status type and own ID token[/COLOR]
[URL="http://www.php.net/return"]return[/URL] [URL="http://www.php.net/substr"]substr[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$Data[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #0000BB]5[/COLOR][COLOR= #007700]);
}[/COLOR]