mIRC Home    About    Download    Register    News    Help

Print Thread
Page 2 of 2 1 2
Joined: Jul 2007
Posts: 1,129
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
I think he is asking for an ascii character operator for evaluation purposes. I'm sure you can use regex along with a custom $ischar identifier for that matter:
Code:
alias -l ischar if ($regex($1-,/(\W+)/S)) return $regml(1) 
on *:TEXT:*:?:if ($ischar($1-)) echo -s WARNING: $nick just used $+(",$v1,") in private.
P.S. I know using an alias is unnecessary, but since westor's brought the $v1 up...I thought it'd be for the best.

Joined: Dec 2008
Posts: 1,515
westor Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Dec 2008
Posts: 1,515
The Riammus has understand what i mean, I gave you examples but i have not more examples, anyway!


Need Online mIRC help or an mIRC Scripting Freelancer? -> https://irc.chathub.org <-
Joined: Jun 2007
Posts: 933
5
Hoopy frood
Offline
Hoopy frood
5
Joined: Jun 2007
Posts: 933
\W? So basically...
Code:
if ($1- !isalnum)

...except that \W also includes the _ character.

Joined: Mar 2004
Posts: 54
Z
Zed Offline
Babel fish
Offline
Babel fish
Z
Joined: Mar 2004
Posts: 54
Code:
if ($len($1-) == 1) && ($1- isalnum) { }

or

if (? iswm $1-) && ($1- isalnum) { }

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Originally Posted By: westor
The Riammus has understand what i mean, I gave you examples but i have not more examples, anyway!


Everything I put in that example was correct? It was just basically random. Anyhow, if that was correct, then the examples using $len and isalnum will work fine except for unicode characters. Might not be a bad idea for isalpha and isalnum to match with unicode such as Japanese.

Anyhow, westor, if anything, your requirements would seem to make more sense for adding issymbol instead of ischar. Not only would it make more sense to people as far as what it's checking, but it would work well with the other is___ checks (you'd then have alpha,number,symbol to check and I think that would be all you'd need). Of course, what a symbol is would have to be determined for that and opinions on that may differ from person to person... probably why it's not there.


Invision Support
#Invision on irc.irchighway.net
Page 2 of 2 1 2

Link Copied to Clipboard