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

	<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>2006-06-12T09:37:19-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Sparky66]]></name></author>
		<updated>2006-06-12T09:37:19-04:00</updated>

		<published>2006-06-12T09:37:19-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=63929#p63929</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=63929#p63929"/>
		<title type="html"><![CDATA[Can anyone get this to work please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=63929#p63929"><![CDATA[
Looking for this script to be fixed if anyone can help<br><blockquote class="uncited"><div>##<br># Parse show info from tv.com<br><br># Enable with .chanset #channel +tv<br><br># [0/1] public or private reply's (public 0, private 1)<br>set tvreply 0<br><br># offset to EST<br># 6 hours makes sense for CET (Europe)<br>set tvoffset 6<br><br>if ![info exists egghttp(version)] {<br>    putlog "egghttp.tcl was NOT successfully loaded."<br>}<br><br>setudef flag tv<br><br>bind pub - !tvinfo pub:info.tv.com<br><br>proc pub:info.tv.com {nick uhost hand chan text} {<br>    if ![channel get $chan tv] return<br>    if {$::tvreply} {set target $nick} {set target $chan}<br>    if {$text==""} {putserv "PRIVMSG $target :Usage: $::lastbind &lt;show&gt;"; return}<br>    set search [join [lrange [split $text] 0 e] {+}]<br>    set d [date:offset [clock seconds] %m%d%y]<br>    set url "<a href="http://www.tv.com/search.php?type=11&amp;stype=program&amp;qs=$search" class="postlink">http://www.tv.com/search.php?type=11&amp;st ... qs=$search</a>"<br>    set sock [egghttp:geturl $url [list findrealurl:tv.com $target] -headers "Cookie: tv_promo_$d=1"]<br>}<br><br>proc findrealurl:tv.com {target sock} {<br>    set data [egghttp:data $sock]<br>    egghttp:cleanup $sock<br>   <br>    foreach line [split $data \n] {<br>        if [string match -noc "*returned no results*" $line] {<br>            putserv "PRIVMSG $target :Unknown show."<br>            return<br>        }<br>         if [string match -noc *www.tv.com*\/show\/*summary.html* $line] {<br>            regexp -nocase {(http://)[^\"]+} $line url<br>            set d [date:offset [clock seconds] %m%d%y]<br>            set s [egghttp:geturl $url [list parseinfo:tv.com $target $url] -headers "Cookie: tv_promo_$d=1"]<br>            return<br>        }<br>    }<br>}<br><br>proc parseinfo:tv.com {target url sock} {<br>    set data [egghttp:data $sock]<br>    egghttp:cleanup $sock<br>   <br>    set data [string map {"\n" "" "&lt;/div&gt;" "&lt;/div&gt;\n" "&lt;br /&gt;" "&lt;br /&gt;\n"} $data]<br>    set dV 0<br>    set ended "0"<br>    foreach line [split $data \n] {<br>         if [regexp {&lt;title&gt;(.*).TV Show - } $line . show] {<br>            putserv "PRIVMSG $target :Show: $show"<br>        }<br>        if [string match -nocase "*Airs:*" $line] {<br>            regsub -all {&lt;(.|\n)*?&gt;} $line {} airs<br>            putserv "PRIVMSG $target :[concat [join $airs]]"<br>        }<br>        if [string match -nocase "*Status:*" $line] {<br>            regsub -all {&lt;(.|\n)*?&gt;} $line {} status<br>            if {[concat [join $status]] == "Status: Ended"} { set ended "1" }<br>            putserv "PRIVMSG $target :[concat [join $status]]"<br>        }<br>        if [string match -nocase "*Premiered*" $line] {<br>            regsub -all {&lt;(.|\n)*?&gt;} $line {} premiered<br>            putserv "PRIVMSG $target :[concat [join $premiered]]"<br>        }<br>        if [string match -nocase "*Show Category:*" $line] {<br>            regsub -all {&lt;(.|\n)*?&gt;} $line {} category<br>            putserv "PRIVMSG $target :[concat [join $category]]"<br>        }<br>        if [string match -nocase "*f-bold f-medium f-red mb-5*" $line] {<br>            regsub -all {&lt;(.|\n)*?&gt;} $line {} Dates<br>            if ![string match -nocase "*Premiered*" $line] {<br>                if {$dV == 0} {<br>                    if {$ended == "1"} {<br>                        putserv "PRIVMSG $target :First Air Date: [concat [join $Dates]]"<br>                    } else {<br>                        putserv "PRIVMSG $target :Next Air Date: [concat [join $Dates]]"<br>                    }<br>                } else {<br>                    putserv "PRIVMSG $target :Last Air Date: [concat [join $Dates]]"<br>                }<br>                incr dV<br>            }<br>        }<br>    }<br>    putserv "PRIVMSG $target :URL: $url"<br>}<br><br>proc date:offset {epox arg} {<br>    set t [expr $epox-((60*60)*$::tvoffset)]<br>    set w [clock format $t -format $arg]<br>    return $w<br>} </div></blockquote>this is what its saying <br><blockquote class="uncited"><div>[2:29pm] &lt;+didibot&gt; Show: Lost<br>[2:29pm] &lt;+didibot&gt; Airs Next: ABC at Wednesday 8:00 PM (60 min.) Status: Returning Series    <br>Premiered: September 22, 2004<br>[2:29pm] &lt;+didibot&gt; Airs Next: ABC at Wednesday 8:00 PM (60 min.) Status: Returning Series    <br>Premiered: September 22, 2004<br>[2:29pm] &lt;+didibot&gt; URL: <a href="http://www.tv.com/lost/show/24313/summary.html?q=lost&amp;tag=search_results;imag" class="postlink">http://www.tv.com/lost/show/24313/summa ... sults;imag</a><br>e;0</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7863">Sparky66</a> — Mon Jun 12, 2006 9:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[JAFO]]></name></author>
		<updated>2006-05-14T05:44:28-04:00</updated>

		<published>2006-05-14T05:44:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62992#p62992</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62992#p62992"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62992#p62992"><![CDATA[
try the tvrage version. Should be around here somewhere <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";)" title="Wink"><br><br><a href="http://forum.egghelp.org/viewtopic.php?t=11208" class="postlink">http://forum.egghelp.org/viewtopic.php?t=11208</a> <br><br>there it is ,<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6850">JAFO</a> — Sun May 14, 2006 5:44 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[skipyy]]></name></author>
		<updated>2006-04-22T12:58:33-04:00</updated>

		<published>2006-04-22T12:58:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62221#p62221</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62221#p62221"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62221#p62221"><![CDATA[
can some1 please finish this script? :X<br>only the next episode and last episode are important<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7676">skipyy</a> — Sat Apr 22, 2006 12:58 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[silver]]></name></author>
		<updated>2006-04-18T23:17:10-04:00</updated>

		<published>2006-04-18T23:17:10-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62087#p62087</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62087#p62087"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62087#p62087"><![CDATA[
jup, tv.com changed layout/scripts again :s<br><br>i started on modding it to work again but blah.. too lazy :&gt;<br>here's how far i was <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";)" title="Wink"><br><br>change <br>  set url "<a href="http://www.tv.com/search.php?type=11&amp;stype=program&amp;qs=$search&amp;search=Search/" class="postlink">http://www.tv.com/search.php?type=11&amp;st ... ch=Search/</a>"<br>to<br>  set url "<a href="http://www.tv.com/search.php?type=11&amp;stype=program&amp;qs=$search" class="postlink">http://www.tv.com/search.php?type=11&amp;st ... qs=$search</a>"<br><br>change<br>  if [string match -noc *www.tv.com*show*summary.html* $line] {<br>to<br>  if [string match -noc *www.tv.com*\/show\/*summary.html* $line] {<br>(cuz there's multiple <a href="http://www.tv.com/shows/blabla/summarty.html" class="postlink">http://www.tv.com/shows/blabla/summarty.html</a> links in the html now)<br><br>change<br>   if [regexp {&lt;title&gt;(.*).TV Show} $line . show] {<br>to<br>   if [regexp {&lt;title&gt;(.*).TV Show - } $line . show] {<br><br>etc,etc <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>its a bit harder to parse now... also it seems like there's some flood protection now as search.php sometimes returns empty page, could be wrong tho<br><br>maybe someone else wants to finish? <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=7660">silver</a> — Tue Apr 18, 2006 11:17 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Bman]]></name></author>
		<updated>2006-04-18T19:49:05-04:00</updated>

		<published>2006-04-18T19:49:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62081#p62081</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62081#p62081"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62081#p62081"><![CDATA[
[06:42:38PM] &lt;@|Bman|&gt; !tvinfo 24<br>[06:42:43PM] -CIA- URL: <a href="http://www.tv.com/talk-show/genre/13/summary.html" class="postlink">http://www.tv.com/talk-show/genre/13/summary.html</a><br><br>yeah i get the same errors<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7575">Bman</a> — Tue Apr 18, 2006 7:49 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[hpostiga]]></name></author>
		<updated>2006-04-17T20:02:14-04:00</updated>

		<published>2006-04-17T20:02:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62048#p62048</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62048#p62048"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62048#p62048"><![CDATA[
the script don't work now :s<br><br>[00:53:05] &lt;@H_P0STiGa&gt; !tvinfo the o.c<br>[00:53:30] &lt;@Up2yoU-Team&gt; URL: <a href="http://www.tv.com/talk-show/genre/13/summary.html" class="postlink">http://www.tv.com/talk-show/genre/13/summary.html</a><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7161">hpostiga</a> — Mon Apr 17, 2006 8:02 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[semaja2]]></name></author>
		<updated>2006-03-18T22:40:58-04:00</updated>

		<published>2006-03-18T22:40:58-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=61169#p61169</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=61169#p61169"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=61169#p61169"><![CDATA[
hey im trying to get this script to work but when i try to do !tv stargate it doesnt say anything, any ideas?<br><br>UPDATE: i now get this error in the windrop logs unexpected integer but got "1142703097.0"<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7519">semaja2</a> — Sat Mar 18, 2006 10:40 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[JAFO]]></name></author>
		<updated>2006-02-15T05:38:29-04:00</updated>

		<published>2006-02-15T05:38:29-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=60438#p60438</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=60438#p60438"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=60438#p60438"><![CDATA[
thx for updating <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6850">JAFO</a> — Wed Feb 15, 2006 5:38 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[FriedCPU]]></name></author>
		<updated>2005-12-03T00:14:19-04:00</updated>

		<published>2005-12-03T00:14:19-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=57901#p57901</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=57901#p57901"/>
		<title type="html"><![CDATA[Some changes]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=57901#p57901"><![CDATA[
Hey<br>I like the script, very nice <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br>I made a few changes.<br>1) the way the adjusted script posted above grabs the next/prev date information, it done it by match 200*, meaning shows only in the year 2000+<br>2) for shows that have ended, it now says "first aired, last aired" instead of "next, last" which makes more sense.<br><br>note: i changed it back to +tv not +tvi, sorry if this is a problem for some people<div class="codebox"><p>Code: </p><pre><code>#### Parse show info from tv.com# Enable with .chanset #channel +tv# [0/1] public or private reply's (public 0, private 1)set tvreply 0# offset to EST# 6 hours makes sense for CET (Europe)set tvoffset 6if ![info exists egghttp(version)] {    putlog "egghttp.tcl was NOT successfully loaded."}setudef flag tvbind pub - !tvinfo pub:info.tv.comproc pub:info.tv.com {nick uhost hand chan text} {    if ![channel get $chan tv] return    if {$::tvreply} {set target $nick} {set target $chan}    if {$text==""} {putserv "PRIVMSG $target :Usage: $::lastbind &lt;show&gt;"; return}    set search [join [lrange [split $text] 0 e] {+}]    set d [date:offset [clock seconds] %m%d%y]    set url "http://www.tv.com/search.php?type=11&amp;stype=program&amp;qs=$search&amp;search=Search/"    set sock [egghttp:geturl $url [list findrealurl:tv.com $target] -headers "Cookie: tv_promo_$d=1"]}proc findrealurl:tv.com {target sock} {    set data [egghttp:data $sock]    egghttp:cleanup $sock        foreach line [split $data \n] {        if [string match -noc "*returned no results*" $line] {            putserv "PRIVMSG $target :Unknown show."            return        }        if [string match -noc *www.tv.com*show*summary.html* $line] {            regexp -nocase {(http://)[^\"]+} $line url            set d [date:offset [clock seconds] %m%d%y]            set s [egghttp:geturl $url [list parseinfo:tv.com $target $url] -headers "Cookie: tv_promo_$d=1"]            return        }    }}proc parseinfo:tv.com {target url sock} {    set data [egghttp:data $sock]    egghttp:cleanup $sock        set data [string map {"\n" "" "&lt;/div&gt;" "&lt;/div&gt;\n" "&lt;br /&gt;" "&lt;br /&gt;\n"} $data]    set dV 0    set ended "0"    foreach line [split $data \n] {        if [regexp {&lt;title&gt;(.*).TV Show} $line . show] {            putserv "PRIVMSG $target :Show: $show"        }        if [string match -nocase "*Airs:*" $line] {            regsub -all {&lt;(.|\n)*?&gt;} $line {} airs            putserv "PRIVMSG $target :[concat [join $airs]]"        }        if [string match -nocase "*Status:*" $line] {            regsub -all {&lt;(.|\n)*?&gt;} $line {} status            if {[concat [join $status]] == "Status: Ended"} { set ended "1" }            putserv "PRIVMSG $target :[concat [join $status]]"        }        if [string match -nocase "*Premiered*" $line] {            regsub -all {&lt;(.|\n)*?&gt;} $line {} premiered            putserv "PRIVMSG $target :[concat [join $premiered]]"        }        if [string match -nocase "*Show Category:*" $line] {            regsub -all {&lt;(.|\n)*?&gt;} $line {} category            putserv "PRIVMSG $target :[concat [join $category]]"        }        if [string match -nocase "*f-bold f-medium f-red mb-5*" $line] {            regsub -all {&lt;(.|\n)*?&gt;} $line {} Dates            if ![string match -nocase "*Premiered*" $line] {                if {$dV == 0} {                    if {$ended == "1"} {                        putserv "PRIVMSG $target :First Air Date: [concat [join $Dates]]"                    } else {                        putserv "PRIVMSG $target :Next Air Date: [concat [join $Dates]]"                    }                } else {                    putserv "PRIVMSG $target :Last Air Date: [concat [join $Dates]]"                }                incr dV            }        }    }    putserv "PRIVMSG $target :URL: $url"}proc date:offset {epox arg} {    set t [expr $epox-((60*60)*$::tvoffset)]    set w [clock format $t -format $arg]    return $w}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7062">FriedCPU</a> — Sat Dec 03, 2005 12:14 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[outthere]]></name></author>
		<updated>2005-11-26T19:36:06-04:00</updated>

		<published>2005-11-26T19:36:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=57726#p57726</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=57726#p57726"/>
		<title type="html"><![CDATA[error]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=57726#p57726"><![CDATA[
wow.. i have been looking for something like this... thx<br><br>i am getting an error though when i do !tvinfo ep<br><br>Tcl error [pub:info.tv.com]: invalid command name "Â "<br><br>i checked egghttp and tvi tcl and cant find that text anywhere..<br>i think it might be a simple problem a noob like me doesnt know anything about.. any help would be greatly appreciated...<br><br>thx  <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=7035">outthere</a> — Sat Nov 26, 2005 7:36 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[pEeDy]]></name></author>
		<updated>2005-11-01T19:52:40-04:00</updated>

		<published>2005-11-01T19:52:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=56967#p56967</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=56967#p56967"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=56967#p56967"><![CDATA[
Where do I type this '.chanset #channel +tvi' ?? I tried in a query, a private message and in channel... DCC chat doesn't work... help me please? <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_sad.gif" width="15" height="15" alt=":(" title="Sad"><br><br>Edit; got it <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br>For other noobs:<br>You have to put it in your telnet window <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br>And you have to load egghttp.tcl too, before you load this tcl script.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6918">pEeDy</a> — Tue Nov 01, 2005 7:52 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Taz]]></name></author>
		<updated>2005-10-23T22:22:21-04:00</updated>

		<published>2005-10-23T22:22:21-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=56785#p56785</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=56785#p56785"/>
		<title type="html"><![CDATA[Thanx]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=56785#p56785"><![CDATA[
Thanx to you and your friend JAFO.  This is exactly what a lot of us wanted.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6890">Taz</a> — Sun Oct 23, 2005 10:22 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[InsideTheBox]]></name></author>
		<updated>2005-10-17T17:58:44-04:00</updated>

		<published>2005-10-17T17:58:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=56682#p56682</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=56682#p56682"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=56682#p56682"><![CDATA[
&lt;luciverse&gt; !tvinfo The Ultimate Fighter<br><br>Tcl error [pub.tvinfo.com]: unknown channel command: should be one of: add, set, info, remove<br><br> <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_cry.gif" width="15" height="15" alt=":cry:" title="Crying or Very sad"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6867">InsideTheBox</a> — Mon Oct 17, 2005 5:58 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[JAFO]]></name></author>
		<updated>2005-10-17T12:27:39-04:00</updated>

		<published>2005-10-17T12:27:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=56677#p56677</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=56677#p56677"/>
		<title type="html"><![CDATA[Tv.com tv show info grabber?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=56677#p56677"><![CDATA[
A friend of mine did a lil work on the script<br><div class="codebox"><p>Code: </p><pre><code>#### Parse show info from tv.com# Enable with .chanset #channel +tvi# [0/1] public or private reply's (public 0, private 1)set tvreply 0# offset to EST# 6 hours makes sense for CET (Europe)set tvoffset 6if ![info exists egghttp(version)] {  putlog "egghttp.tcl was NOT successfully loaded."}setudef flag tvibind pub - !tvinfo pub:info.tv.comproc pub:info.tv.com {nick uhost hand chan text} {  if ![channel get $chan tvi] return  if {$::tvreply} {set target $nick} {set target $chan}  if {$text==""} {putserv "PRIVMSG $target :Usage: $::lastbind &lt;show&gt;"; return}  set search [join [lrange [split $text] 0 e] {+}]  set d [date:offset [clock seconds] %m%d%y]  set url "http://www.tv.com/search.php?type=11&amp;stype=program&amp;qs=$search&amp;search=Search/"  set sock [egghttp:geturl $url [list findrealurl:tv.com $target] -headers "Cookie: tv_promo_$d=1"]}proc findrealurl:tv.com {target sock} { set data [egghttp:data $sock] egghttp:cleanup $sock foreach line [split $data \n] {  if [string match -noc "*returned no results*" $line] {    putserv "PRIVMSG $target :Unknown show."    return  }  if [string match -noc *www.tv.com*show*summary.html* $line] {    regexp -nocase {(http://)[^\"]+} $line url    set d [date:offset [clock seconds] %m%d%y]    set s [egghttp:geturl $url [list parseinfo:tv.com $target $url] -headers "Cookie: tv_promo_$d=1"]    return  } }}proc parseinfo:tv.com {target url sock} { set data [egghttp:data $sock] egghttp:cleanup $sock set data [string map {"\n" "" "&lt;/div&gt;" "&lt;/div&gt;\n" "&lt;br /&gt;" "&lt;br /&gt;\n"} $data] set dV 0 foreach line [split $data \n] {   if [regexp {&lt;title&gt;(.*).TV Show} $line . show] {     putserv "PRIVMSG $target :Show: $show"   }   if [string match -nocase "*Airs:*" $line] {     regsub -all {&lt;(.|\n)*?&gt;} $line {} airs     putserv "PRIVMSG $target :[concat [join $airs]]"   }   if [string match -nocase "*Status:*" $line] {     regsub -all {&lt;(.|\n)*?&gt;} $line {} status     putserv "PRIVMSG $target :[concat [join $status]]"   }   if [string match -nocase "*Premiered*" $line] {     regsub -all {&lt;(.|\n)*?&gt;} $line {} premiered     putserv "PRIVMSG $target :[concat [join $premiered]]"   }   if [string match -nocase "*Show Category:*" $line] {     regsub -all {&lt;(.|\n)*?&gt;} $line {} category     putserv "PRIVMSG $target :[concat [join $category]]"   }   if [string match -nocase "*, 200*" $line] {     regsub -all {&lt;(.|\n)*?&gt;} $line {} Dates     if ![string match -nocase "*Premiered*" $line] {       if {$dV == 0} {         putserv "PRIVMSG $target :Next Air Date: [concat [join $Dates]]"       } else {         putserv "PRIVMSG $target :Last Air Date: [concat [join $Dates]]"       }       incr dV     }   } } putserv "PRIVMSG $target :URL: $url"}proc date:offset {epox arg} { set t [expr $epox-((60*60)*$::tvoffset)] set w [clock format $t -format $arg] return $w}</code></pre></div><br>.chanset changed also from +tv &gt;&gt;&gt; +tvi ( coz i allready used +tv in tv.com.tcl v0.2 by greenbear )<br><br>Might contain unlogical data , but it works <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br><div class="codebox"><p>Code: </p><pre><code>&lt;~me&gt; !tvinfo 24&lt;@MyBot&gt; Show: 24&lt;@MyBot&gt; Airs: Monday 9:00 PM on FOX (60 mins)&lt;@MyBot&gt; Status: Returning Series&lt;@MyBot&gt; Premiered November 6, 2001&lt;@MyBot&gt; Show Category: Action/Adventure , Drama&lt;@MyBot&gt; Next Air Date: Sunday January 15, 2006&lt;@MyBot&gt; Last Air Date: Monday May 23, 2005&lt;@MyBot&gt; URL: http://www.tv.com/24/show/3866/summary.html?q=24</code></pre></div>Njoy <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=6850">JAFO</a> — Mon Oct 17, 2005 12:27 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[cBuster]]></name></author>
		<updated>2005-09-23T04:53:59-04:00</updated>

		<published>2005-09-23T04:53:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=56014#p56014</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=56014#p56014"/>
		<title type="html"><![CDATA[Re: The information is not on the site to parse ..]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=56014#p56014"><![CDATA[
<blockquote class="uncited"><div>The information u request is not on the site to parse as yet , it would be better to find a different site to parse the info that you require , if you can find a good one that doesnt change its layout to often i would be happy to code this for you ....</div></blockquote>You can always use <a href="http://epguides.com/PrisonBreak/" class="postlink">http://epguides.com/PrisonBreak/</a>. (ex)<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6755">cBuster</a> — Fri Sep 23, 2005 4:53 am</p><hr />
]]></content>
	</entry>
	</feed>
