problem with retrieving data from socket - 09/05/04 09:16 PM
I have a socket connect to a web page and I want to diplay a line from that page in chan.
With this code I retrieve the whole page (and the script exit for excess flood);
on *:sockread:mySockName:{
if ($sockerr > 0) return
:nextread
else {
sockread -f %scasttemp
if ($sockbr == 0) return
if (%scasttemp == $null) %scasttemp = empty
msg $active %scasttemp
}
}
Instead I want display only a single line from the middle of the web page, this line
<font size="2" face="Verdana, Arial, Helvetica, sans-serif" color="#464646"><small>
I_WAS_LOOKING_FOR_THIS_LINE<br>
</small></font>
Can someone help me? Thanks!
With this code I retrieve the whole page (and the script exit for excess flood);
on *:sockread:mySockName:{
if ($sockerr > 0) return
:nextread
else {
sockread -f %scasttemp
if ($sockbr == 0) return
if (%scasttemp == $null) %scasttemp = empty
msg $active %scasttemp
}
}
Instead I want display only a single line from the middle of the web page, this line
<font size="2" face="Verdana, Arial, Helvetica, sans-serif" color="#464646"><small>
I_WAS_LOOKING_FOR_THIS_LINE<br>
</small></font>
Can someone help me? Thanks!