IceShaman commented on a Page, Easy Modes  -  Feb 10, 2006

on :input:: {
if ($regex($1,^(\+|-)([a-zA-Z])$)) {
var %sign = $regml(1), %mode = $regml(2)
if (%mode isincs cImi) { mode $active $1 }
elseif (%mode isincs vhoaq) {
if (%sign == +) { cs $replacex(%mode,v,voice,h,halfop,o,op,a,protect,q,owner) $active $me }
else { mode $active $1 $me }
}
elseif (%mode isincs QpstACGMKNORSTVu) { mode $active $1 $me }
halt
}
}

quick replacement for the snippet, includes checking to make sure $1 is in the exact format of + or - followed by 1 singular letter...

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.