<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/6896" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2004-02-21T09:59:29-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/6896</id>

		<entry>
		<author><name><![CDATA[CoMMy]]></name></author>
		<updated>2004-02-21T09:59:29-04:00</updated>

		<published>2004-02-21T09:59:29-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33795#p33795</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33795#p33795"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33795#p33795"><![CDATA[
Thanks man. That did the trick!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz">  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_lol.gif" width="15" height="15" alt=":lol:" title="Laughing">  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3555">CoMMy</a> — Sat Feb 21, 2004 9:59 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2004-02-20T18:53:11-04:00</updated>

		<published>2004-02-20T18:53:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33775#p33775</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33775#p33775"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33775#p33775"><![CDATA[
That was one thing to change, the other is what Cucumber said hehe. You have your arguments mixed up for string match.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Fri Feb 20, 2004 6:53 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CoMMy]]></name></author>
		<updated>2004-02-20T18:29:34-04:00</updated>

		<published>2004-02-20T18:29:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33774#p33774</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33774#p33774"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33774#p33774"><![CDATA[
Thanks for that stdragon. I missed it. but code still doesnt work.<br>It doesnt give out any errors but it doesnt unbind!!!<br><br>this is what we have.<br><div class="codebox"><p>Code: </p><pre><code>foreach binding [binds] { set bindtype [lindex $binding 0] set bindattr [lindex $binding 1] set bindname [lindex $binding 2] set bindhits [lindex $binding 3] set bindproc [lindex $binding 4] if {[string match [string tolower $bindproc] [string tolower msg_*]]} { unbind $bindtype $bindattr $bindname $bindproc }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3555">CoMMy</a> — Fri Feb 20, 2004 6:29 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2004-02-20T16:05:07-04:00</updated>

		<published>2004-02-20T16:05:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33768#p33768</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33768#p33768"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33768#p33768"><![CDATA[
Except he's trying to do wildcard matching, so string equal won't work.<br><br>Commy, the other problem is that it sounds like you want to match the proc name (msg_*) but the code currently matches bind type (msg, msgm, pub, etc). So you have two things to change.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Fri Feb 20, 2004 4:05 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-02-20T15:35:18-04:00</updated>

		<published>2004-02-20T15:35:18-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33767#p33767</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33767#p33767"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33767#p33767"><![CDATA[
Instead of using two "string tolower" in a "string match" better use "string equal -nocase" directly. Example:<br>if {[string equal -nocase $foo $bar]} { # do something }<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Fri Feb 20, 2004 3:35 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-02-20T13:20:11-04:00</updated>

		<published>2004-02-20T13:20:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33763#p33763</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33763#p33763"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33763#p33763"><![CDATA[
Howdy,<br><br>i think you've got your string match params switched. it should be [string match pattern string] and it seems you have [string match string pattern]<br><br>also change msg to msg* in your pattern<br><br><br><br>                                              \\//_<p>Statistics: Posted by Guest — Fri Feb 20, 2004 1:20 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CoMMy]]></name></author>
		<updated>2004-02-20T11:37:16-04:00</updated>

		<published>2004-02-20T11:37:16-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33760#p33760</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33760#p33760"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33760#p33760"><![CDATA[
Anyone?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3555">CoMMy</a> — Fri Feb 20, 2004 11:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CoMMy]]></name></author>
		<updated>2004-02-20T09:34:02-04:00</updated>

		<published>2004-02-20T09:34:02-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=33756#p33756</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=33756#p33756"/>
		<title type="html"><![CDATA[Help With Wildcards In a loop.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=33756#p33756"><![CDATA[
This is my problem.<br><div class="codebox"><p>Code: </p><pre><code>foreach binding [binds] {set bindtype [lindex $binding 0]set bindattr [lindex $binding 1]set bindname [lindex $binding 2]set bindhits [lindex $binding 3]set bindproc [lindex $binding 4]if {[string match [string tolower $bindtype] [string tolower msg]]} {unbind $bindtype $bindattr $bindname $bindproc }}</code></pre></div>Where it says [string tolower msg] I want to change msg into<br>msg_* but it doesnt work.<br><br>Can you help me find this?<br>Basically i want something to select every bind that has a msg_ proc.<br><br>Thanks <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=":wink:" title="Wink"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3555">CoMMy</a> — Fri Feb 20, 2004 9:34 am</p><hr />
]]></content>
	</entry>
	</feed>
