PHP:
1
| <?if ($_POST['submit'] != "") {/*Thanks for Andrew Heebner <php@evilwalrus.com> for ideas*/$username = str_replace(" ", "+", $_POST['username']);$useremail = str_replace(" ", "+", $_POST['useremail']);$subject = str_replace(" ", "+", $_POST['subject']);$message = "[subject: $subject]";$message .= "[username: $username]";$message .= "[date: " . date("D-m-Y") . " @ " . date("H-i") . "]";$message .= "[message: " .$_POST['message'] . "]";$message = str_replace(" ", "+", $message);$icqnum = $_POST['icqnum'];$arr = @file("http://wwp.icq.com/scripts/online.dll?icq=" . $icqnum . "&img=1");$len = strlen($arr[1]);if ($len == "") echo "status=Status is Local Server&";if ($len == 96) echo "status=Status is Online&";if ($len == 83) echo "status=Status is Offline&";if ($len == 1) echo "status=Status is Disabled&";$url = "http://wwp.icq.com/scripts/WWPMsg.dll?to=" . $icqnum . "&fromemail=" . $useremail . "&from=" . $username . "&body=" . $message;$fd = fopen($url, "r");while ($n < 4) { $buffer = fgets($fd, 4096); $n++;}if (strlen($buffer)>10) { echo "info=Message send !&something";}else{ echo "info=Sending failed...&something";}fclose($fd);}else{?><html><head><title>Send a ICQ msg to someone.</title></head><form method=post action='icq.php?uin=21702135'><table width=425 border=0 cellpadding=2 cellspacing=0> <tr> <td valign=top>&nbsp; </td> <td valign=top><br>Verstuur ICQ message naar UIN <input type="text" name="icqnum" value="icq number" size="10" maxlength="12"></td> </tr> <tr> <td valign=top><b>Username</b> </td> <td valign=top><input type="text" name="username" value="yourname" size="25" maxlength="40"></td> </tr> <tr> <td valign=top><b>Email address</b></td> <td valign=top><input type="text" name="useremail" value="your email" size="25" maxlength="128"></td> </tr> <tr> <td valign=top><b>Subject</b></td> <td valign=top><input type="text" name="subject" value="Subject" size="25" maxlength="40"></td> </tr> <tr> <td valign=top> <b>Message</b></td> <td valign=top> <textarea name="message" cols="30" rows="7" wrap="virtual"></textarea> <p>Your IP address is also attatched to this messaget.<p><input type="submit" name="submit" value="Send message"></td> </tr></table></form></body></html><?}?> |
geeft alleen errors op de volgende regels.
status=Status is Local Server&
Warning: fopen("http://...@hotmail.com&from=username&body=[subject:+onderwerp][username:+username][date:+Wed-07-2002+@+22-03][message:+dit+is+mijn+msg]", "r") - No error in e:\forum\icq.php on line 36
Warning: fgets(): supplied argument is not a valid File-Handle resource in e:\forum\icq.php on line 38
Warning: fgets(): supplied argument is not a valid File-Handle resource in e:\forum\icq.php on line 38
Warning: fgets(): supplied argument is not a valid File-Handle resource in e:\forum\icq.php on line 38
Warning: fgets(): supplied argument is not a valid File-Handle resource in e:\forum\icq.php on line 38
info=Sending failed...&something
Warning: fclose(): supplied argument is not a valid File-Handle resource in e:\forum\icq.php on line 46