This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

TCL and Regular Expressions....

Old posts that have not been replied to for several years.
Locked
C
Cla75

Post by Cla75 »

A simple binding like this...

bind pubm - * pub_msg
proc pub_msg {nick uhost hand chan text} {
if {![regexp "hello bot" $text]} { return }
putserv "PRIVMSG $chan :$nick, hello :smile:"
}

works only if the words digits is equal to "hello bot", and not if the digit is "bot hello!" o something similar....

Anyone have any idea to how to use regular expressions, for this? in example....reply anyway if anyone says hello my beautiful bot, or bot, hello how do you do?

Tnx.... i don't have much familiarity with regular expressions....but i think it can be done.... tnx :smile:
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

{bot.*hello|hello.*bot}
Locked