Wildcards in Inline Alias Script

Posted by 1of10 on Thu 19 Jun 2003 06:05 AM — 3 posts, 20,369 views.

Canada #0
I'm using an inline script in an alias to send text, using wildcards captured from the alias.

^vocp (\w*)( \w*)?$

How do I access the wildcards from the inline script? ${$_[2]}[0], which I use in the script file subroutines to access the wildcards, does not appear to work in an inline script. $1, which is used by Perl with pattern matches, doesn't work either. %1, documented in MUclient help, also doesn't work. I even tried \1, which is used in my text/code editor for it's pattern matches (if Perl-like RegExp isn't enabled).

Am I missing a subtle escaping problem, or something?
Australia Forum Administrator #1
I think I had trouble accessing VB arrays in Perlscript, which is why you can use GetAliasInfo to access the wildcards. See:

http://www.gammon.com.au/scripts/doc.php?function=getaliasinfo


In particular, see selectors 101 to 110.
Canada #2
Finally got the inline script to work properly, after monkeying with subtle quoting problems... ;)

I was wondering what purpose the alias wildcard access selectors would have when I read about them oh so long ago. I wish I'd remembered about them when creating the alias. ;p

Thanks much for the refresher. :)