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

	<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-07-12T03:01:22-04:00</updated>

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

		<entry>
		<author><name><![CDATA[NewzUK]]></name></author>
		<updated>2004-07-12T03:01:22-04:00</updated>

		<published>2004-07-12T03:01:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38460#p38460</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38460#p38460"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38460#p38460"><![CDATA[
then it didnt send the msg to the channel...<br><br>but I've solved the problem by making a separate proc for the msg to the channel, and triggering that after the setting of the variables - now it's not repeating  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> <br><br>thanks for the help though!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2210">NewzUK</a> — Mon Jul 12, 2004 3:01 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2004-07-09T17:03:39-04:00</updated>

		<published>2004-07-09T17:03:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38394#p38394</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38394#p38394"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38394#p38394"><![CDATA[
Ooops what about after the else? (but still inside the main if part)<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Fri Jul 09, 2004 5:03 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[NewzUK]]></name></author>
		<updated>2004-07-09T06:44:48-04:00</updated>

		<published>2004-07-09T06:44:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38382#p38382</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38382#p38382"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38382#p38382"><![CDATA[
just tried it and still no luck...<br>this is what the problem looks like:<br>[22:40:16] &lt;iNews&gt;  [GE] GE 'CONFIDENT' OF 10%-15% EPS GROWTH FOR 2005  <br>[22:40:47] &lt;iNews&gt;  [GE] GE REVISES FULL-YEAR EARNS RANGE TO $1.55-$1.60/SHR  <br>[22:41:16] &lt;iNews&gt;  [GE] GE 'CONFIDENT' OF 10%-15% EPS GROWTH FOR 2005  <br>[22:41:48] &lt;iNews&gt;  [GE] GE REVISES FULL-YEAR EARNS RANGE TO $1.55-$1.60/SHR  <br>[22:42:16] &lt;iNews&gt;  [GE] GE 'CONFIDENT' OF 10%-15% EPS GROWTH FOR 2005  <br>[22:42:46] &lt;iNews&gt;  [GE] GE REVISES FULL-YEAR EARNS RANGE TO $1.55-$1.60/SHR  <br><br>top 2 headlines just repeat and dosn't stop at the first one, even with the check to see if it's old or not...<br>aghrrr<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2210">NewzUK</a> — Fri Jul 09, 2004 6:44 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2004-07-08T20:31:40-04:00</updated>

		<published>2004-07-08T20:31:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38367#p38367</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38367#p38367"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38367#p38367"><![CDATA[
Try putting the return after this line:<br><br>putserv "PRIVMSG #channel :/0034,4 /0031,15 $rtr /00314,14 /003"<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Thu Jul 08, 2004 8:31 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[NewzUK]]></name></author>
		<updated>2004-07-06T22:04:32-04:00</updated>

		<published>2004-07-06T22:04:32-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38300#p38300</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38300#p38300"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38300#p38300"><![CDATA[
thanks strikelight - have put a return in at the end ( I think that's the right position?), and for the individual calls, it stops and just sends the top line. But the next time it runs, if that first story hasn't changed, instead of stopping, it gets the second oldest story. It's hard to explain...not sure how else I can demonstrate?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2210">NewzUK</a> — Tue Jul 06, 2004 10:04 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[strikelight]]></name></author>
		<updated>2004-06-30T20:00:31-04:00</updated>

		<published>2004-06-30T20:00:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38065#p38065</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38065#p38065"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38065#p38065"><![CDATA[
Break from the loop and procedure by calling "return" where you want it to exit...<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2005">strikelight</a> — Wed Jun 30, 2004 8:00 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[NewzUK]]></name></author>
		<updated>2004-06-30T05:03:10-04:00</updated>

		<published>2004-06-30T05:03:10-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=38044#p38044</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=38044#p38044"/>
		<title type="html"><![CDATA[constraining socket data]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=38044#p38044"><![CDATA[
Hi - This relates sort of to a previous script I've sought help on - please excuse the long explaination!<br>I have a script to retrieve news headlines from a website - and with help from here, I've set up a check using variables so that the headlines don't repeat if there isn't a new one since the last check. <br>This works fine on the sites that only have one news headine on the page, however, when I try to use it on a page that has a list of headlines where there is no unique html code to identify only the newest top headline, the check system goes haywire.<br>It gets the top line, then on the next check, it sees that it is the same as before and instead of stopping, goes onto the next story down and sends that to the channel. On the next check it goes back and sends the first story and so it carries on between the top 2 headlines.<br>Is there a way I can force the script to not go past the first line I'm trying to retrieve in the script so this back-and-forth can't happen?<br><br>Here's the proc I'm using:<div class="codebox"><p>Code: </p><pre><code>proc getrtr {sock} {     global rtrurl rtrold     set headers [egghttp:headers $sock]     set body [egghttp:data $sock]     egghttp:cleanup $sock     foreach line [split $body \n] {       if {[string match "*52_*" $line]} {         set rtr [gettok $line 2 62]         set rtr [gettok $rtr 0 60]         set rtrurl [gettok $line 5 34]         if ($rtr != $rtrold)} {           putserv "PRIVMSG #channel :/0034,4 /0031,15 $rtr /00314,14 /003"         } else {           set rtrold $rtr         }       }     } } </code></pre></div>Thanks for any help!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_confused.gif" width="15" height="15" alt=":-?" title="Confused"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2210">NewzUK</a> — Wed Jun 30, 2004 5:03 am</p><hr />
]]></content>
	</entry>
	</feed>
