Title: Message
Thank you very much, it really did help.
Mike.
 
 
-----Original Message-----
From: Simon Boddy [mailto:[EMAIL PROTECTED]
Sent: Friday, June 13, 2003 6:40 AM
To: [EMAIL PROTECTED]
Subject: RE: Witango-Talk: Question on <@REGEX ...> Does it really work?

Hi,
the \w special character is specific to perl. The equivalent in standard (extended) regex is [:alnum:]. There may be other components that are non standard. There are certainly a couple I don't recognise. regex in Tango certainly works, you just have a bit of work to do to rejig you _expression_ ;-)
 
Regards Simon
 
  -----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 13 June 2003 10:14
To: [EMAIL PROTECTED]
Subject: Witango-Talk: Question on <@REGEX ...> Does it really work?

Hello all,
 
I have a question regarding the metatag <@REGEX >, which I can not  make it work.
In the code below, I have two identical fragments, except for the STR string.
All I am trying to do is to verify if the STR is a valid email address. The regular _expression_, EXPR, I verified to work fine in _javascript_, Perl and ASP. But I cannot figure out how it should be made to work in a taf file, and the documentation is useless.
 
When I run this code I always get exaclty the same result, <@VARINFO ..> reporting TEXT, and the variable local$re returns M,  weather the email string is valid or not.
 
Any ideas?
 
Many thanks,
Mike.


<@!  ------------------ STR = valid email address -------------------- >
<@ASSIGN NAME=local$re
        VALUE='<@REGEX EXPR="\w+([-+.]\w+)[EMAIL PROTECTED]([-.]\w+)*\.\w+([-.]\w+)*"      
        STR="[EMAIL PROTECTED]
        TYPE=B>'
>

<@VARINFO NAME=local$re ATTRIBUTE=TYPE> <@! this displays TEXT>
result = @@local$re <br>          <@! this displays M >

<@!  --------------------- STR = invalid email address ---------------- >
<@ASSIGN NAME=local$re
        VALUE='<@REGEX EXPR="\w+([-+.]\w+)[EMAIL PROTECTED]([-.]\w+)*\.\w+([-.]\w+)*"      
        STR="[EMAIL PROTECTED]@hotmail.com
        TYPE=B>'
>

<@VARINFO NAME=local$re ATTRIBUTE=TYPE> <@! this displays TEXT>
result = @@local$re <br>          <@! this displays M >


________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf


********************************************************************
This message is intended only for the use of the person(s) ("the intended
recipient(s)") to whom it is addressed. It may contain information which is
privileged and confidential within the meaning of applicable law. If you
are not the intended recipient, please contact the sender as soon as
possible. The views expressed in this communication may not necessarily
be the views held by LGCSB (Local Government Computer Services Board).

Any attachments have been checked by a virus scanner and appear to be
clean.
Please ensure that you also scan all messages, as LGCSB does not accept
any liability for contamination or damage to your systems.
********************************************************************
________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf

Reply via email to