<?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/13072" />

	<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>2007-02-03T09:55:39-04:00</updated>

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

		<entry>
		<author><name><![CDATA[heman]]></name></author>
		<updated>2007-02-03T09:55:39-04:00</updated>

		<published>2007-02-03T09:55:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=70179#p70179</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=70179#p70179"/>
		<title type="html"><![CDATA[different announcement by different count]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=70179#p70179"><![CDATA[
that seems to work to <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br><br>Thanks<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8556">heman</a> — Sat Feb 03, 2007 9:55 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[dwickie]]></name></author>
		<updated>2007-02-03T09:42:18-04:00</updated>

		<published>2007-02-03T09:42:18-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=70178#p70178</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=70178#p70178"/>
		<title type="html"><![CDATA[different announcement by different count]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=70178#p70178"><![CDATA[
something like that?<br><div class="codebox"><p>Code: </p><pre><code>set maxresults 10if {$cnt&gt;=$maxresults} {  putserv "PRIVMSG $chan :found $cnt results: sending latest $maxresults result:"} else {  putserv "PRIVMSG $chan :found $cnt results: sending result:"}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5343">dwickie</a> — Sat Feb 03, 2007 9:42 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[heman]]></name></author>
		<updated>2007-02-03T08:21:41-04:00</updated>

		<published>2007-02-03T08:21:41-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=70177#p70177</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=70177#p70177"/>
		<title type="html"><![CDATA[different announcement by different count]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=70177#p70177"><![CDATA[
When someone query's the db it returns announcement to irc channel: like this:<blockquote class="uncited"><div>&lt;botname&gt; sending latest results:</div></blockquote>(the max results is set to 10)<br><br><br>Now I want to let it announce how many records of that query it has found in the db, so i added to the script:<div class="codebox"><p>Code: </p><pre><code>    set cnt [mysqlsel $db "select count(*) from $table WHERE nm = '$text';" -list]</code></pre></div>And changed the announcement in:<blockquote class="uncited"><div>&lt;botname&gt; found ## results: sending latest results:"</div></blockquote><br>Now what I liked to add is it will announce the ## results, someting like:<blockquote class="uncited"><div>&lt;botname&gt; found 1 result: sending latest 1 result:"<br><br>&lt;botname&gt; found 5 result: sending latest 5 results:"<br><br>&lt;botname&gt; found 23 result: sending latest 10 result:"<br><br>etc.</div></blockquote><br>I was thinking to do it someting like this:<br><div class="codebox"><p>Code: </p><pre><code>    if ........ {        putserv "PRIVMSG $chan :found $cnt result: sending latest 1 result:"    } elseif {      ......... {        putserv "PRIVMSG $chan :found $cnt results: sending latest 2 results:"    } elseif {      ......... {        putserv "PRIVMSG $chan :found $cnt results: sending latest 3 results:"    etc    } else {      ......... {        putserv "PRIVMSG $chan :found $cnt results: sending latest 10 result:"    } </code></pre></div>But I have no idea what I have to fill in on the .......<br><br>Anyone can help me?<br><br>Thanks<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8556">heman</a> — Sat Feb 03, 2007 8:21 am</p><hr />
]]></content>
	</entry>
	</feed>
