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

	<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>2003-11-19T07:58:33-04:00</updated>

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

		<entry>
		<author><name><![CDATA[user]]></name></author>
		<updated>2003-11-19T07:58:33-04:00</updated>

		<published>2003-11-19T07:58:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=30312#p30312</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=30312#p30312"/>
		<title type="html"><![CDATA[Result of my script into channel topic?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=30312#p30312"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code># this bind will call the proc below once every hourbind time - 00* ftps:timedproc ftps:timed args {# this calculation makes sure it's only run at hours 00, 02, 04 etcif {![expr {[format %g [lindex $args 1]]%2}]} {# remember to change the channel name below :)ftps {} {} {} #channel {}}}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2878">user</a> — Wed Nov 19, 2003 7:58 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2003-11-19T07:18:30-04:00</updated>

		<published>2003-11-19T07:18:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=30311#p30311</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=30311#p30311"/>
		<title type="html"><![CDATA[Result of my script into channel topic?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=30311#p30311"><![CDATA[
Thanks for your quick help! Works great! Now one last thing... I want that the scripts runs every 2 hours. Is that possible somehow?<p>Statistics: Posted by Guest — Wed Nov 19, 2003 7:18 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[user]]></name></author>
		<updated>2003-11-18T19:37:35-04:00</updated>

		<published>2003-11-18T19:37:35-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=30283#p30283</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=30283#p30283"/>
		<title type="html"><![CDATA[Re: Result of my script into channel topic?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=30283#p30283"><![CDATA[
Why have one proc for each ftp?<div class="codebox"><p>Code: </p><pre><code>package require ftpbind pub - .ftp ftpsproc ftps {nick uhost hand chan arg} {set out {}# just add your ftps to this list (make sure you don't# leave any fields blank or mess up the order :P)set list {{"FTP 1" ftp.addr1.cum 444 login pass}{"FTP 2" ftp.addr2.cum 21 login pass}{"FTP 3" ftp.addr3.cum 3131 login pass}{"FTP 4" ftp.addr4.cum 9999 login pass}}foreach ftp $list {foreach {name addr port user pass} $ftp breakset ftp [ftp::Open $addr $user $pass -port $port]if {$ftp&lt;0} {lappend out "$name is down"} {lappend out "$name is up"}ftp::Close $ftp}putserv "TOPIC $chan :[join $out " | "]"}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2878">user</a> — Tue Nov 18, 2003 7:37 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2003-11-18T16:18:11-04:00</updated>

		<published>2003-11-18T16:18:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=30270#p30270</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=30270#p30270"/>
		<title type="html"><![CDATA[Result of my script into channel topic?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=30270#p30270"><![CDATA[
Hi Guys!<br><br>I made a small script wich checks if a FTP Server is up or down and shows the result of the test in an irc channel. Works fine so far. Now to my question. Is it possible, that the result of the script is put into the channel topic? It should look something like this <br>"FTP 1 up | FTP 2 up | FTP 3 down | FTP 4 up".<br>Is that possible somehow?<br><div class="codebox"><p>Code: </p><pre><code> package require ftpbind pub - .ftp ftpproc ftp { nick uhost hand chan arg } {ftp1 $nick $uhost $hand $chan $arg ftp2 $nick $uhost $hand $chan $arg ftp3 $nick $uhost $hand $chan $arg ftp4 $nick $uhost $hand $chan $arg}proc ftp1 { nick uhost hand chan arg } {set biglist1 {xxx.xxx.xxx.xxx log pas}foreach {addr uid pwd} $biglist1 { set statval [ftp::Open $addr $uid $pwd -port 444] if {$statval&lt;0} {    putserv "PRIVMSG $chan : \002FTP 1\002 \0034down\0034!" } else {    putserv "PRIVMSG $chan : \002FTP 1\002 \0039up\0039!"    ftp::Close $statval;  } }}proc ftp2 { nick uhost hand chan arg } {set biglist2 {xxx.xxx.xxx.xxx log pas}foreach {addr uid pwd} $biglist2 { set statval [ftp::Open $addr $uid $pwd -port 444] if {$statval&lt;0} {    putserv "PRIVMSG $chan : \002FTP 2\002 \0034down\0034!" } else {    putserv "PRIVMSG $chan : \002FTP 2\002 \0039up\0039!"    ftp::Close $statval;  } }}proc ftp3 { nick uhost hand chan arg } {set biglist3 {xxx.xxx.xxx.xxx log pas}foreach {addr uid pwd} $biglist3 { set statval [ftp::Open $addr $uid $pwd -port 444] if {$statval&lt;0} {    putserv "PRIVMSG $chan : \002FTP 3\002 \0034down\0034!" } else {    putserv "PRIVMSG $chan : \002FTP 3\002   \0039up\0039!"    ftp::Close $statval;  } }}proc ftp4 { nick uhost hand chan arg } {set biglist4 {xxx.xxx.xxx.xxx log pas}foreach {addr uid pwd} $biglist4 { set statval [ftp::Open $addr $uid $pwd -port 444] if {$statval&lt;0} {    putserv "PRIVMSG $chan : \002FTP 4\002 \0034:(\0034" } else {    putserv "PRIVMSG $chan : \002FTP 4\002   \0039:)\0039"    ftp::Close $statval;  } }}putlog "Loaded ftp_test.tcl by DigitalXXL"</code></pre></div><p>Statistics: Posted by Guest — Tue Nov 18, 2003 4:18 pm</p><hr />
]]></content>
	</entry>
	</feed>
