Bonjour, est-ce que qqu'un saurait m'aider a convertir ce script en asp :
Je vous en remercie d avance. Tibow
/*
################ VSIRC Roomlister v1.0 ################
IRC Roomlister..
This script is created by M.Kollaard and M.D.Bakker
For information you can always send a email to:
(info@vilestyle.net) or (helpdesk@vilestyle.net)
Copyrighted (c) 2003-2008 VSNetworks©
When you modify the contents in this script
Please Add THe Copyrights Line..
Have Fun with it...
################ VSIRC ServiceBot v1.2 ################
*/
//set_time_limit(off);
$botnick = "Synapse";
$server = "e-deality.com";
$port = "6667";
$channel = "G1N";
?>#<?=stripslashes($channel);?><br>
<font color="#000000">Salles Officielles E-Deality</font>
<font color="#000000"> </font></font></p>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber1">
<tr>
<td width="6%" bgcolor="#00CCFF" height="16">
<div align="center"><img src="images/users.gif" width="16" height="16"></div>
</td>
<td width="24%" bgcolor="#00CCFF" height="16">Nom de la
salle </td>
<td width="70%" bgcolor="#00CCFF" height="16">Sujets de
conversations </td>
</tr>
<?
$fp = fsockopen($server, $port, $errno, $errstr, 30);
if (!$fp) {
echo "$errstr ($errno)<br />\n";
} else {
fputs($fp,"USER $botnick $botnick 127.0.0.1 :php\n");
$nick = $botnick . rand(10000,99999);
fputs($fp,"NICK $nick\n");
while (!feof($fp)) {
usleep(50);
$fget = @fgets($fp, 128);
//echo "$fget <br>\n";
$match = explode(" ", $fget);
$fget = ereg_replace ("\n", "", $fget);
$fget = ereg_replace ("\r", "", $fget);
if ($match[1] == "001") {
fputs($fp,"LIST\n");
} else if ($match[0] == "PING") {
fputs($fp, "PONG :" . $match[1]);
} else if ($match[1] == "433") {
$nick = $botnick . rand(10000,99999);
fputs($fp,"NICK $nick\n");
} else if ($match[1] == "323") {
fputs($fp, "QUIT :bye!\n");
break;
} else if ($match[1] == "322") {
$match[3] = ereg_replace ("#", "", $match[3]);
if (eregi ("$channel(.*)", $match[3], $chan)) {
$topic = explode(":", $fget);
unset($topic[0]);
unset($topic[1]);
$topic = implode(":", $topic);
$topic = explode(" ", $topic);
unset($topic[0]);
$topic = implode(" ", $topic);
if ($color == "FFFFCC") { $color = "FFFFFF"; } else { $color = "FFFFCC"; }
?>
<tr>
<td width="6%" bgcolor="#<?=$color?>"> <?=$match[4]; ?></td>
<td width="24%" bgcolor="#<?=$color?>"> <a href="chat.php?catagory=G1N&room=<?=$chan[1]; ?>"><?=$chan[1]; ?></a></td>
<td width="70%" bgcolor="#<?=$color?>"> <?=$topic;?></td>
</tr>
<?
}
}
}
fclose($fp);
}
?>
Partager