Hey all, i have a textfile with loads of lines. I want the user in the channel to search within this file and get the results (max 5) returned.
The problem is that i only want the the first, the third and the fourth item to show from the line. I came up with this:
ON *:TEXT:!search*:#mychannel: {
var %string = $2-
msg $chan Searching for %string
window -h @@
filter -fw C:\quotes.txt @@ $+(*,%string,*)
msg $chan There were $filtered quotes found showing 5
if $filtered { savebuf 5 @@ quotes.tmp | write quotes.tmp End of results | play $nick quotes.tmp 1000 | .remove quotes.tmp
window -c @@ }
}
This only gives back the entire line it found a result on instead of giving the the first, the third and the fourth part of the line.
Would you have a solution for my problem?
Thanks, you guys are the best!