I tried using a "while"
Code:
sockread 950 &ip
  var %ip.br $calc(950 - $sockbr)
  echo -s br0-> %ip.br - sbr-> $sockbr
  while (%ip.br > 0) {
    echo -s br1-> %ip.br
    sockread %ip.br &ip
    %ip.br = $calc(%ip.br - $sockbr)
    echo -s br1.5-> %ip.br - sbr-> $sockbr
  }

but the second sockread always read 0 byte and mirc crash.

Maybe now I found an easier way, but i've another problem.
If i read using a normal sockread %ip i reach the blue lines with the info that i need.
Code:
 [color:blue]><td nowrap align=center>83.184.189.90</td><td nowrap align=center>IT</td><td nowrap align=center>ITALY
 (...) <td nowrap align=center>TELE2 ITALY S.A  [/color]  

at the end of the lines there is a CRLF then there's this line
Code:
 [color:green] </td><td nowrap align=center><a target=_new href="http://www.ip2state.com/map.asp?s=ip&city=REDMOND&lat=47.6738&long=-122.089&ses=457666932"><img border=0 src="images/mapit.gif">
 (...) <center> [/color]  

and last
Code:
  [color:red]   <form action="/free.asp" method="POST"> [/color]  


Now, when I read, in the var i've the blue part, if i read again in the var i've the red one, the green one seems disappear.

Just after the first sockread i did an echo of the bytes read and they was 496, but, in the %var, there are just 265bytes (the blue part).
It seems to read the blue and the green part from the buffer but just the green part go in the var.

This is the code i'm using (i also tried several combination with and without binvar)
Code:
 
  if ( Map  isin %ip) {
      ; Map  is in the line just before the blue part
      sockread 512 &ip
      ;here i read the blue and the green part
      set %ip $bvar(&ip,1,$sockbr).text
      ;here i copy all the bytes read
      echo -s br-> $sockbr ip-> %ip
      ...
}

but the echo is:
br-> 496 ip-> ><td nowrap align=center>83.184.189.90</td><td nowrap align=center>IT</td><td nowrap align=center>ITALY</td> (...) <td nowrap align=center>TELE2 ITALY S.A
is the var cut when there is the CRLF at the end of this line?
i also tried to write the var in the file but there's no way to see the green part :\