mIRC Home    About    Download    Register    News    Help

Print Thread
#5313 07/01/03 04:12 AM
Joined: Jan 2003
Posts: 5
R
rimini Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
R
Joined: Jan 2003
Posts: 5
I have a very simple socket script that reads a page from a http server and echoes the results in a window. In fact its the sample script mentioned in mIRC help file. I have a problem though. Some lines in the page are quit big! The script fills a variable (%temp) and then echoes that variable. What I get is the "line too long" error!
I know variables have a limit for the information they can hold. I assume that the "line too long" error is from that limit but is there a way to get over it? Maybe not using a variable but something (?) else?
I have searched the board here but found nothing on my topic...
Thank you in advance

#5314 07/01/03 10:48 AM
Joined: Dec 2002
Posts: 66
Babel fish
Offline
Babel fish
Joined: Dec 2002
Posts: 66
What I do is use $mid to grab the first 930 chars, ie:

on 1:sockread:blah: {
var %tmp
sockread %tmp
%tmp = $mid(%tmp,1,930)
tokenize 32 %tmp

if ($$1-) echo -a $ifmatch
}


- Linux System Administrator, Darktides Communications, LLC.
#5315 10/01/03 04:38 PM
Joined: Jan 2003
Posts: 5
R
rimini Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
R
Joined: Jan 2003
Posts: 5
Thank you! That worked fine!! grin


Link Copied to Clipboard