
05.03.2008, 20:27
|
|
Познающий
Регистрация: 13.03.2007
Сообщений: 75
Провел на форуме: 268754
Репутация:
13
|
|
У меня есть скриптик как раз....я его чу чуть переделал...и вот чё вышло....
Код HTML:
<html>
<head>
<title>CHECKER</title>
<meta http-equiv="Content-Type" content="text/html; charset=cp2151">
<body bgcolor="#000000" text="#ffffff">
<center><table border="0"><tr><td><center><font color="green"><b>| Введите UIN |</b></font></center></td></tr>
<tr><td><form action="<? $PHP_SELF ?>" method="post">
<font color=\"green\"><b>UIN:</b></font> <input type="text" name="uin"></td></tr><tr><td><center><input type="submit" value="Проверить"></center></td></tr></table>
<?php
$new=$_POST['uin']; // номер
$cr=curl_init("http://webwarper.net/ww/~av/kanicq.ru/invisible/?method=2");
curl_setopt($cr, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322)");
curl_setopt($cr, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_0);
curl_setopt($cr, CURLOPT_TIMEOUT, 20);
curl_setopt($cr, CURLOPT_HEADER, 1);
curl_setopt($cr, CURLOPT_POSTFIELDS, "human=1&uin=$new&youwereadded=on&uin4login=&password4login=");
curl_setopt($cr, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($cr, CURLOPT_REFERER, "http://icq-online.ru");
$r = curl_exec($cr);
curl_close($cr);
$s = "echo '$r'";
if ( preg_match ("/Free for chat/i" , "$s")) { $status = "Готов к общению"; }
elseif ( preg_match ("/Online/i" ,"$s")) { $status = "Онлайн"; }
elseif ( preg_match ("/Away/i" , "$s")) { $status = "Отошел"; }
elseif ( preg_match ("/N\/A/i" , "$s")) { $status = "Недоступен"; }
elseif ( preg_match ("/Occupied/i" , "$s")) { $status = "Занят"; }
elseif ( preg_match ("/DND/i" , "$s")) { $status = "Не беспокоить"; }
elseif ( preg_match ("/offline/i" , "$s")) { $status = "Оффлайн"; }
elseif ( preg_match ("/status\/invisible/i" , "$s")) { $status = "Невидимый"; }
else { $status = "Неизвестно"; }
echo "<font color=\"green\"><b>UIN:</b></font><font color=\"red\"> $new</font> <font color=\"green\"><b>Статус:</b></font><font color=\"red\"> $status</font>";
?>
</td></tr></table></center>
</body>
</head>
</html>
Получается мой искрипт для бота будет выглядеть как...
PHP код:
// !инвиз
else if (preg_match("#^!инвиз#", $msg_text))
{
preg_match("#\s+(.+)#", $msg_text, $uin);
if(!empty($msg[0]))
{
////////////тут код О_О ?!//////////////////////
{
$send .= $uin;
}
}
блин....если честно то чета я в этом боте нииифига не фкуриваю О_О
|
|
|