| View previous topic :: View next topic |
| Author |
Message |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Fri Mar 03, 2006 7:45 pm Post subject: |
|
|
| Code: | set badnicks "\
sex \
s3x \
\{ \
\\ \
\[ \
\] \
\}
" |
This is incorrect, badnicks is a string here and not a list. Use
| Code: | set badnicks {
"sex"
"s3x"
"\{"
"\\"
"\["
"\]"
"\}"
} |
[ would've worked perfectly if [string equal] was used instead of [string match] since [] has special meaning in [string match] so using \[ will solve the problem.
PS: That wouldn't work if [list] was used instead of {}. If [list] is used, then you'll have to add {\[} or \\\[ instead of just \[. _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
demond Revered One

Joined: 12 Jun 2004 Posts: 3073 Location: San Francisco, CA
|
Posted: Sat Mar 04, 2006 12:41 am Post subject: |
|
|
| rosc2112 wrote: | | How is it my fault that your script can't handle [ as part of a banned channel name? |
it's your fault that you think my script can't handle it, and it can; it's your fault than you are unable to escape correctly square brackets in a regexp; and unfortunately, you can't seem to comprehend what I'm saying to you
| Quote: |
Really, if you all don't know the answer, why bother replying? |
I know every answer of every question about xchannel.tcl; I wrote the thing, remember?
anyhow, it's commendable you bothered to help yourself and write a script that - albeit naive and buggy - works for you _________________ connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use [code] tag when posting logs, code |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|