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

	<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>2017-09-02T08:21:20-04:00</updated>

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

		<entry>
		<author><name><![CDATA[SamSun]]></name></author>
		<updated>2017-09-02T08:21:20-04:00</updated>

		<published>2017-09-02T08:21:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106415#p106415</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106415#p106415"/>
		<title type="html"><![CDATA[horoscop.tcl]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106415#p106415"><![CDATA[
Hi tried the script and i got this error <blockquote class="uncited"><div>RAC: &lt;iframe frameBorder=\"0\" width=\"auto\" id=\"dailyHoroscopeFrame\" style=\"min-width: 550px\" src=\"<a href="http://www.sentimente.ro/horoscop/index/daily-zodii/?signId=rac&amp;zodii=1&amp;fs=12&amp;currentAction=zilnic%5C%22%3E%3C/iframe" class="postlink">http://www.sentimente.ro/horoscop/index ... "&gt;&lt;/iframe</a>&gt;</div></blockquote>Website changed i guess but i don`t know how to fix the script to work again.If someone can take a look at the script and make that change. Thank You.<br><br>Here is the script:<div class="codebox"><p>Code: </p><pre><code>namespace eval zodiac {    package require http    setudef flag horoscop    bind pub -|- !horoscop [namespace current]::fetch    proc fetch {nick uhost hand chan text} {       if {![channel get $chan horoscop]} return       if {[scan $text {%s} sign] != 1} {          putserv "NOTICE $nick :Syntax: !horoscop &lt;zodiac sign&gt;"          return       }       set signs [list "berbec" "taur" "gemeni" "rac" "leu" "fecioara" "balanta" "scorpion" "sagetator" "capricorn" "varsator" "pesti"]       set sign [string tolower $sign]       if {[lsearch $signs $sign] == -1} {          putserv "NOTICE $nick :Error, $sign is a uknown sign. Pick another."          return       }       set http [::http::geturl "http://www.zodii.ro/zodiac/$sign*zodie_$sign-horoscop_zilnic.html"]       set data [::http::data $http]       ::http::cleanup $http       regexp -nocase {&lt;div class="textArticol"&gt;(.*?)&lt;/div&gt;} $data text       set result [lrange $text 2 end-1]       putserv "NOTICE $nick :[string toupper $sign]: $result"    } }</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12710">SamSun</a> — Sat Sep 02, 2017 8:21 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Arnold_X-P]]></name></author>
		<updated>2016-06-20T18:48:50-04:00</updated>

		<published>2016-06-20T18:48:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105204#p105204</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105204#p105204"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105204#p105204"><![CDATA[
hi caesar<br>It is possible that your tcl<br>You can modify and read from :<br><br>&gt;&gt;&gt;   <a href="http://www.horoscope.com/" class="postlink">http://www.horoscope.com/</a><br><br><br>thanks<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8327">Arnold_X-P</a> — Mon Jun 20, 2016 6:48 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-20T16:26:25-04:00</updated>

		<published>2016-06-20T16:26:25-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105201#p105201</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105201#p105201"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105201#p105201"><![CDATA[
I don`t want to open a new topic so i will write here, i have a new problem with a code that worked fine untill the shell went down. I`ve re-uploaded but give`s me an error. This is the code:<br><br><br><span style="color:green">if {![info exists anuntpublic:show_running]} {<br>timer $black(anunttime) anuntpublic:show<br>set anuntpublic:show_running 1</span><br><br><br><br><strong class="text-strong">Error: can't read "black(anunt_time)": no such element in array<br>    while executing<br>"timer $black(anunt_time) anuntpublic_show       "<br></strong><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Mon Jun 20, 2016 4:26 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-20T16:20:22-04:00</updated>

		<published>2016-06-20T16:20:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105200#p105200</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105200#p105200"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105200#p105200"><![CDATA[
Yes <strong class="text-strong">juanamores</strong>, this time <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Mon Jun 20, 2016 4:20 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2016-06-18T00:56:51-04:00</updated>

		<published>2016-06-18T00:56:51-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105188#p105188</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105188#p105188"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105188#p105188"><![CDATA[
<blockquote class="uncited"><div>Yes! Its working great. Thank you for your help <strong class="text-strong">caesar</strong></div></blockquote>You did it, XtremeSeb !<br>I 'll make a post to see if anyone help me with sockets.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Sat Jun 18, 2016 12:56 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-12T10:08:05-04:00</updated>

		<published>2016-06-12T10:08:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105162#p105162</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105162#p105162"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105162#p105162"><![CDATA[
Yes! Its working great. Thank you for your help <strong class="text-strong">caesar</strong><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sun Jun 12, 2016 10:08 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-06-12T05:39:34-04:00</updated>

		<published>2016-06-12T05:39:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105160#p105160</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105160#p105160"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105160#p105160"><![CDATA[
As for the other script I take it the <em class="text-italics">check:N:gl</em>,<em class="text-italics"> check:n:gl</em> and <em class="text-italics">check<img alt=":m:" class="emoji smilies" draggable="false" src="//cdn.jsdelivr.net/gh/twitter/twemoji@latest/assets/svg/24c2.svg">gl</em> is a proc that basically is checking if the user has the global N, n or m flag.<br><br>Easy to change things so instead of <em class="text-italics">check:N:gl $hand</em> can dirrectly use  <em class="text-italics">matchattr $hand N</em> and for the other two <em class="text-italics">matchattr $hand n</em> and <em class="text-italics">matchattr $hand m</em>.<br><br>Oh and instead of:<div class="codebox"><p>Code: </p><pre><code>if {[string equal -nocase $nick $botnick]} {return}</code></pre></div>I would actually use:<div class="codebox"><p>Code: </p><pre><code>if {[isbotnick $nick]} return</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Sun Jun 12, 2016 5:39 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-12T03:29:31-04:00</updated>

		<published>2016-06-12T03:29:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105159#p105159</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105159#p105159"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105159#p105159"><![CDATA[
Done! Its working great. Thanks again.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sun Jun 12, 2016 3:29 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-12T03:06:26-04:00</updated>

		<published>2016-06-12T03:06:26-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105158#p105158</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105158#p105158"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105158#p105158"><![CDATA[
Yees its working fine, thank you so much caesar. But he answers to the user with notice. Can he reply on main?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sun Jun 12, 2016 3:06 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-06-12T02:34:34-04:00</updated>

		<published>2016-06-12T02:34:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105157#p105157</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105157#p105157"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105157#p105157"><![CDATA[
As I was testing stuff mixed variables and now should work fine. Replace:<div class="codebox"><p>Code: </p><pre><code>regexp -nocase {&lt;div class="textArticol"&gt;(.*?)&lt;/div&gt;} $html text</code></pre></div>with:<div class="codebox"><p>Code: </p><pre><code>regexp -nocase {&lt;div class="textArticol"&gt;(.*?)&lt;/div&gt;} $data text</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Sun Jun 12, 2016 2:34 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-11T19:41:20-04:00</updated>

		<published>2016-06-11T19:41:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105156#p105156</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105156#p105156"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105156#p105156"><![CDATA[
The same script works fine on another eggdrop. But the owner is offline for a lot of time..<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sat Jun 11, 2016 7:41 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2016-06-11T19:29:26-04:00</updated>

		<published>2016-06-11T19:29:26-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105155#p105155</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105155#p105155"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105155#p105155"><![CDATA[
<blockquote class="uncited"><div>If anyone has a horoscope  tcl that works , please post it.</div></blockquote>The problem with all scripts who use sockets is that web pages change and the code stops working.<br>I have tried several but none worked. <br>I hope you have luck and someone shares one that works.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Sat Jun 11, 2016 7:29 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-11T12:57:01-04:00</updated>

		<published>2016-06-11T12:57:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105152#p105152</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105152#p105152"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105152#p105152"><![CDATA[
If anyone has a horoscope  tcl that works , please post it.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sat Jun 11, 2016 12:57 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[XtremeSeb]]></name></author>
		<updated>2016-06-11T12:25:10-04:00</updated>

		<published>2016-06-11T12:25:10-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105151#p105151</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105151#p105151"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105151#p105151"><![CDATA[
I get this error now - Tcl error [::zodiac::fetch]: can't read "html": no such variable<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12630">XtremeSeb</a> — Sat Jun 11, 2016 12:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-06-12T02:31:52-04:00</updated>

		<published>2016-06-11T12:14:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105150#p105150</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105150#p105150"/>
		<title type="html"><![CDATA[Error on script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105150#p105150"><![CDATA[
You get that error on first cos the regexp doesn't match anything and thus he doesn't create the <em class="text-italics">horoscopo</em> and gives you an error when trying to use something hasn't been defined.<br><br>Haven't tested so give a try to:<div class="codebox"><p>Code: </p><pre><code>namespace eval zodiac {package require httpsetudef flag horoscopbind pub -|- !horoscop [namespace current]::fetchproc fetch {nick uhost hand chan text} {if {![channel get $chan horoscop]} returnif {[scan $text {%s} sign] != 1} {putserv "NOTICE $nick :Syntax: !horoscop &lt;zodiac sign&gt;"return}set signs [list "berbec" "taur" "gemeni" "rac" "leu" "fecioara" "balanta" "scorpion" "sagetator" "capricorn" "varsator" "pesti"]set sign [string tolower $sign]if {[lsearch $signs $sign] == -1} {putserv "NOTICE $nick :Error, $sign is a uknown sign. Pick another."return}set http [::http::geturl "http://www.zodii.ro/zodiac/$sign*zodie_$sign-horoscop_zilnic.html"]set data [::http::data $http]::http::cleanup $httpregexp -nocase {&lt;div class="textArticol"&gt;(.*?)&lt;/div&gt;} $data textset result [lrange $text 2 end-1]putserv "NOTICE $nick :[string toupper $sign]: $result"} }</code></pre></div>I'm not a regexp guru so I bet someone will come with a better solution than mine. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>As for the second, you are missing a chunk of that script cos it's not finding the <em class="text-italics">check<img alt=":m:" class="emoji smilies" draggable="false" src="//cdn.jsdelivr.net/gh/twitter/twemoji@latest/assets/svg/24c2.svg">gl</em> function (proc).<br><br>Edit: Fixed typo.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Sat Jun 11, 2016 12:14 pm</p><hr />
]]></content>
	</entry>
	</feed>
