Jump to content

We have updated TG007.net. If you notice any problems please let us know.

Dippy

Ircx Roomlist

Recommended Posts

having a problem with this code it giving me

/socklisten: bind error (line 2, script2.ini)

can anyone help?

 

on *:START:{ liststart }
alias liststart { socklisten listing 6668 }
on *:socklisten:listing:{ sockaccept sendlist. $+ $r(111,999) }
on *:sockread:sendlist.*:{ var %r | sockread %r | tokenize 32 %r
  if ($1 == ROOMLIST) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <center><b>Liste Des salles:</b><br>
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 90%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="Black">
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White">Users</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">Nom de la salle</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">Sujet</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">Modes</font></b><br></td></tr>
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) { sockwrite -tn $sockname <tr bgcolor="bbbbbb"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2),\b,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,modes,room) </font></td></tr> | dec %a }
	    elseif (%a == 1) { sockwrite -tn $sockname <tr bgcolor="dddddd"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2),\b,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,modes,room) </font></td></tr> | inc %a }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center> |    $sockname
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>ListRooms:</b><br>
	  sockwrite -tn $sockname No room available for the moment
	  sockwrite -tn $sockname </center> |    $sockname
    }
  }
  else { sockclose $sockname }
}
alias    {
  sockwrite $1 $decode(PGJyPjxjZW50ZXI+PGEgaHJlZj0iaHR0cDovL3BhcGVyY2hhdC5mcmVlLmZyLyI+PGZvbnQgc2l6ZT0iMSI+UGFnZSBDcunpZSBQYXIgUGFwZXJJUkMgTVNOTGlrZSBTZXJ2ZXI8L2ZvbnQ+PC9hPjwvY2VudGVyPg==,m)
}

Share this post


Link to post
Share on other sites

hmmm.. you could try..

 

alias liststart { socklisten -d listing 6668 }

Which chat network is this for?

Edited by d33j4y

Share this post


Link to post
Share on other sites

this what I'm trying to do

 

using this code to call the roomlist

 

<?php
error_reporting (E_ALL);
$service_port = 6668;
$address = gethostbyname ('86.6.32.133');
$socket = socket_create (AF_INET, SOCK_STREAM, 0);
if ($socket < 0) {
    echo "socket_create() Error: " . socket_strerror ($socket) . "\n";
}
$result = socket_connect ($socket, $address, $service_port);
if ($result < 0) {
    echo "socket_connect() Error: ($result) " . socket_strerror($result) . "\n";
}
$in = "ROOMLIST\n";
$out = '';
socket_write ($socket, $in, strlen ($in));
while ($out = socket_read ($socket, 2048)) {
    echo $out;
}
socket_close ($socket);
?>

and then use this code to reply back

 

on *:START:{ liststart }
alias liststart { socklisten listing 6668 }
on *:socklisten:listing:{ sockaccept sendlist. $+ $r(111,999) }
on *:sockread:sendlist.*:{ var %r | sockread %r | tokenize 32 %r
  if ($1 == ROOMLIST) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <center><b>List rooms:</b><br>
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 90%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="Black">
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White">Users</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">RoomName</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">topic</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="1" color="White">Modes</font></b><br></td></tr>
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) { sockwrite -tn $sockname <tr bgcolor="bbbbbb"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2),\b,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,modes,room) </font></td></tr> | dec %a }
	    elseif (%a == 1) { sockwrite -tn $sockname <tr bgcolor="dddddd"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2),\b,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,modes,room) </font></td></tr> | inc %a }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center> |    $sockname
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>List rooms:</b><br>
	  sockwrite -tn $sockname No room available for the moment
	  sockwrite -tn $sockname </center> |    $sockname
    }
  }
  else { sockclose $sockname }
}
alias    {
  sockwrite $1 $decode(PGJyPjxjZW50ZXI+PGEgaHJlZj0iaHR0cDovL3BhcGVyY2hhdC5mcmVlLmZyLyI+PGZvbnQgc2l6ZT0iMSI+UGFnZSBDcunpZSBQYXIgUGFwZXJJUkMgTVNOTGlrZSBTZXJ2ZXI8L2ZvbnQ+PC9hPjwvY2VudGVyPg==,m)
}

but all it does is suck on load then after 10 mins it goes to 500 error

Share this post


Link to post
Share on other sites
I understand, my experience isnt the greatest with the chat network stuff! Only other thing I could think of is some sort of firewall issue perhaps!?!

Share this post


Link to post
Share on other sites

yeh I tried that but the chat itself works on that port 6668 so it got to be something to do with the code

Share this post


Link to post
Share on other sites

I see nothing to trigger a sockopen to read the data the php socket is to return for mirc to use.

 

Were the php is being hosted on? ... ie(webserver, or localhost)

 

why you would be doing this way insted of using listx or list (Only network I seen not use one of the two or both commands was Buzzen)

 

I am not sure what you are doing fully the code you posted looks broken and missing key things to even start to make it work. I am not picking at you in any way, just need more info and hopefully be able to help you get your code working the way you want it to work

Share this post


Link to post
Share on other sites

The irc side it self is on my computer but the php stuff is hosted on hostgator

 

All I want to do is get the roomlist from the ircx server and relay it back to the webserver

Edited by Dippy

Share this post


Link to post
Share on other sites
I see another problem already.. Hostgator does not allow chat to be hosted on their servers!

Share this post


Link to post
Share on other sites

they dont allow the irc to be run on their sever I'm just running the php side on their server and I already have the chat side working on the webserver just not a working room list yet for the ircx server

Share this post


Link to post
Share on other sites

ok got this now but still unable to get it in working order

 

alias cmd {
  if (r isin $readini($+(rooms/ $+ $1 $+ .ini),modes,room)) { return r }
}
alias ishidden {
  if (h isin $readini($+(rooms/ $+ $1 $+ .ini),modes,room)) { return true }
  if (p isin $readini($+(rooms/ $+ $1 $+ .ini),modes,room)) { return true }
  if (s isin $readini($+(rooms/ $+ $1 $+ .ini),modes,room)) { return true }
  else { return false }
}
on *:socklisten:listing:{ sockaccept sendlist. $+ $r(111111,999999) }
on *:sockread:sendlist.*:{ var %r | sockread %r | tokenize 32 %r
  if ($1 == ROOMLIST) {
    if ($var(%create.*,1)) {
	  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;	  sockwrite -tn $sockname <center><b>Room List:</b><br>
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 90%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#9999FF">
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White">Users</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="2" color="White">Room Name</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="2" color="White">Topic</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;"><b><font face="verdana" size="2" color="White">Category</font></b><br></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White">	 </font></b><br></td></tr>
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) { sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "><center>To join</center></a></font></td></tr> | dec %a }
	    elseif (%a == 1) { sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "><center>To join</center></a></font></td></tr> | inc %a }
	    inc %n
	  }
	  ;	  sockwrite -tn $sockname </table></center> |    $sockname
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Rooms List:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTGN) {

    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == GN) && ($ishidden == false) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="2.5"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="2.5"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"><a href=""> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == GN) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFFO"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="2.5"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="2.5"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"><a href=""> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="tahoma" size="2.5"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center> 
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Rooms List:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTCC) {

    if ($var(%create.*,1)) {

	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == CC) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == CC) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center> 
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Room List:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTRM) {
    if ($var(%create.*,1)) {

	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>  

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == RM) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == RM) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  ;;sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) </font></td></tr>
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"><center>Ninguna sala disponible en esta categoria<br>
    }
    if ($sock($sockname)) { sockclose $sockname }
  }

  elseif ($1 == ROOMLISTTN) {

    if ($var(%create.*,1)) { 
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == TN) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == TN) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center> 
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center>
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTIN) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == IN) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == IN) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTFN)  {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == FN) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == FN) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTLS) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == LS) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == LS) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }

  elseif ($1 == ROOMLISTHB) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == HB) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == HB) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }

  elseif ($1 == ROOMLISTSP) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == SP) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == SP) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTNW) {
    if ($var(%create.*,1)) {

	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 
	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == NW) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == NW) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }
  elseif ($1 == ROOMLISTPR) {
    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == PR) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == PR) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }

  elseif ($1 == ROOMLISTRL) {

    if ($var(%create.*,1)) {
	  sockwrite -tn $sockname <table cellpadding="0" cellspacing="1" border="0" style="width: 100%; text-align: left;" bordercolor="#A0a0a0"><tr bgcolor="#ffffff">
	  sockwrite -tn $sockname <td width="5%" height="10" background="pics/tile_back.gif"> <b> </b></td>
	  sockwrite -tn $sockname <td style="vertical-align: top;" width="50"><b><font face="verdana" size="1" color="White"></font></b><br></td>	 
	  sockwrite -tn $sockname <td width="30%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Room Name</b></td>
	  sockwrite -tn $sockname <td width="64%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Topic</b></td>
	  sockwrite -tn $sockname <td width="11%" height="27" background="pics/tile_back.gif"> <b><font face="Tahoma" size=2.5>Language</b></td>	 

	  var %n = 1
	  var %a = 1
	  while (%n <= $var(%create.*,0)) {
	    if (%a == 2) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == RL) {
		  sockwrite -tn $sockname <tr bgcolor="F2F1EE"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  dec %a
	    }
	    elseif (%a == 1) && ($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,category) == RL) {
		  sockwrite -tn $sockname <tr bgcolor="FFFFF0"><td style="vertical-align: top;" width="2%"><font face="tahoma" size="1"> $replace($cmd($gettok($var(%create.*,%n),2,$asc(.))),r,) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $lines(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .txt) </font></td><td style="vertical-align: top;"><font face="verdana" size="2"><a href="chats.php?room= $+ $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) $+ "> $replace($right($gettok($var(%create.*,%n),2,$asc(.)),-2), ,$chr(32)) </font></a></td><td style="vertical-align: top;"><font face="verdana" size="1"> $replace($readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,topic) </font></td><td style="vertical-align: top;"><font face="verdana" size="1"> $readini(rooms/ $+ $gettok($var(%create.*,%n),2,$asc(.)) $+ .ini,info,language),es-mx,Spanish) </font></td>
		  inc %a
	    }
	    inc %n
	  }
	  sockwrite -tn $sockname </table></center>
	  sockclose $sockname
    }
    else {
	  sockwrite -tn $sockname <center><b>Lista de salas:</b><br>
	  sockwrite -tn $sockname No available rooms for the time being
	  sockwrite -tn $sockname </center> |    $sockname
    }
    if ($sock($sockname)) { sockclose $sockname }
  }

}

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×