how to format output to mirc

Back to PHP-IRC Support

Page: 1  
From User Message Body
AmigaSpide
Post #497
Member
Date: 1:05 am, Mar 29 2007
Posts: 18


i`m wondering how to format output from the bot and using the hlserver module. atm i`m using this
$this->ircClass->privMsg($this->server['channel'] , $versus.' '.$type.' '.$date.' '.$map1.'/'.$map2.' '.$status_col .$status. $norm_col.' '.$scores.' '.$colour. $map_win. $norm_col.' id= '.$id);

how do you tabulate data such as this so it would be aligned as
a html table with <td><tr><table> and therefore inline in mirc?
tia
Amiga


Manick
Post #498
user avatar
Admin
Date: 5:19 am, Mar 29 2007
Posts: 223


huh?

--Manick
PHP-IRC Developer
AmigaSpide
Post #499
Member
Date: 5:50 am, Mar 29 2007
Posts: 18


so that you could output headings into irc and have the results from a mysql table align with the headings
eg.

VERSUS TYPE DATE MAP1/MAP2 STATUS SCORES RESULT ID
[En] WPTFCL 01/04/2007 Alchimy_l2/Chimkey_l agreed id= 101
=|O*Z|= WPTFCL 04/03/2007 Voltage_l/raiden3 played 50-0/30-10 WON id= 94

i just don`t know how to line them up :)
Amiga


Mad_Clog
Post #500
user avatar
Member
Date: 7:44 am, Mar 29 2007
Posts: 176


Why not just make the output self explaining
18/01/2007 @ 21:00 NTFCL YOU vs THEM Maps: bases2k3 (45 - 30) & Voltage_l (120 - 90)
Using colors and Switching between bold and none-bold also helps making it more readable

And if you also use this for upcoming wars you could do something like this
Saturday 15/07/2006 @ 21:00 NTFCL YOU vs THEM Maps: schtop & raiden3 [DEF] player, player [OFF] player, player [MB] player, player /\ Comments: Your comments

If you want an example with full markup drop by in #wotr or #madclog (you're on quakenet right?)

AmigaSpide
Post #501
Member
Date: 1:25 pm, Mar 29 2007
Posts: 18


yep thx guys i am using colours
$lost= chr(3).'01,04';
$win = chr(3).'01,09';
$draw = chr(3).'01,07';
hurt my retinas but hey ho :)

and spotted a way to use bold. it does seem to retrieve data from mysql very quickly but i limit it to 7 wars due to spam. that was my next idea mad_clog to allow players to add/remove themselves to wars via a web browser, aswell as from irc also i could add comments/match reports, who played etc.
will pop by irc soon
cheers
Amiga

   

Back to PHP-IRC Support