Top

$FILTOK


mIRC Code
+ 0 likes
Please Register to submit score.
Average Score  8.0
Scores Submitted  1
Date Added  Mar 07, 2008
Last Updated  Mar 07, 2008
Tags  alias  easy  filter  filtok  mirc  tok  token 
  Bookmark and Share

Introduction

Usage: $filttok(TOKEN,RANGE,C)
Example: $filttok(a.b.c.d.e,b-c,46) will return a.d.e

As you can see, it works for both letters and numbers and will filter out the range.

Grab the Code

Comments

  (6)  RSS
^Neptune
Comments: 241
 
mIRC Snippet:  $FILTOK
Posted on Aug 18, 2008 1:33 pm
Nice
This has been criminally overlooked >:[
Purgatory
Comments: 3
 
mIRC Snippet:  $FILTOK
Posted on Aug 31, 2008 4:52 am
intriguing. Very nice.
Scakk
Comments: 218
 
mIRC Snippet:  $FILTOK
Posted on Aug 31, 2008 8:32 am
This looks alot like $deltok

From /help

Code:

$deltok(text,N-N2,C)

Deletes the Nth token from text.

$deltok(a.b.c.d,3,46)        returns a.b.d
$deltok(a.b.c.d,2-3,46)        returns a.d

You can specify a negative value for N.



^Neptune
Comments: 241
 
mIRC Snippet:  $FILTOK
Posted on Aug 31, 2008 8:34 am
Kind of, but it deletes any occurence of the letter.
Scakk
Comments: 218
 
mIRC Snippet:  $FILTOK
Posted on Aug 31, 2008 8:48 am
True.

However I used

//echo -ag $filtok(a.d.r.e.t.e.d.s,d-e,46)

and got left with only "a" when it should have been "a.r.t.s" yes?
^Neptune
Comments: 241
 
mIRC Snippet:  $FILTOK
Posted on Aug 31, 2008 8:52 am
Hmmm yeah. Maybe it would be good so the user could specify letters to filter via a comma, and recognise the last parameter used as the token.

Because if you use d-e for example that's like a range. I mean, what if you wanted to filter "a" and "z" together? You'd filter and get rid of the entire string!

Please Register or Login to start posting comments.
Bottom