Code:
on *:SOCKREAD:TICKET*: {
  sockread &data

  if (*BinarySecurityToken Id="PPToken1">t=* iswm $bvar(&data,1-).text) {
    var %start = $calc($bfind(&data,1,BinarySecurityToken Id="PPToken1">t=) + 34), %end = $bvar(&data,1,</wsse:BinarySecurityToken>)

    var %str = $remove($left($bvar(&data,$+(%start,-,%end)).text,401),amp;)
    echo -a %str
  }
}


Problem I'm getting is * Line too long: $bvar (on the IF statement)

The server actually replies back with a massive xml document which can't be read in 1 sockread line as its too long for mirc. how can i do this then?

the string i'm trying to parse out the whole sockread chunk is
Quote:

<wsse:BinarySecurityToken Id="PPToken1">somelongtokenstringhere123456789</wsse:BinarySecurityToken>

Last edited by pouncer; 25/12/09 01:19 AM.