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

	<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-08-03T13:37:14-04:00</updated>

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

		<entry>
		<author><name><![CDATA[starpossen]]></name></author>
		<updated>2006-08-03T13:37:14-04:00</updated>

		<published>2006-08-03T13:37:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=65123#p65123</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=65123#p65123"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=65123#p65123"><![CDATA[
Hi, I made a post asking almost the same, didnt see this one, but thanks for the link DragnLord.<br><br>Now my original question was:<blockquote class="uncited"><div>Hi.<br>I was wondering if it would be possible to make a script which would check if a site is online/up and the post the result to the channel eg:<br><br>Site is down then the bot would announce in a channel that it was down and keep doing so with intervals<br><br>Site is up then the bot would announce it but only once.<br><br>I don't know if I explained this good enough, I hope so.</div></blockquote>How would I go about doing this with your script DragnLord?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7219">starpossen</a> — Thu Aug 03, 2006 1:37 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[M4ST3R26]]></name></author>
		<updated>2006-06-20T21:28:09-04:00</updated>

		<published>2006-06-20T21:28:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=64231#p64231</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=64231#p64231"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=64231#p64231"><![CDATA[
Thx guys <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";)" title="Wink"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7885">M4ST3R26</a> — Tue Jun 20, 2006 9:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[DragnLord]]></name></author>
		<updated>2006-06-19T02:27:40-04:00</updated>

		<published>2006-06-19T02:27:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=64172#p64172</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=64172#p64172"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=64172#p64172"><![CDATA[
I had posted an older version, this is what I currently use (thought something didn't look right...):<div class="codebox"><p>Code: </p><pre><code>bind pub o !ftptest ftp:testproc ftp:test {n u h c a} { if {[catch {set ftp_test [socket -async $a 21]} sockerr]} {   putserv "privmsg $c :$a reports: $sockerr"   } else {   putserv "privmsg $c :$a reports: [gets $ftp_test]" } close $ftp_test}putlog "FTP Test loaded.."</code></pre></div>On successful connection it retuns ftpd version.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4461">DragnLord</a> — Mon Jun 19, 2006 2:27 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[DragnLord]]></name></author>
		<updated>2006-06-19T01:40:42-04:00</updated>

		<published>2006-06-19T01:40:42-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=64170#p64170</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=64170#p64170"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=64170#p64170"><![CDATA[
I have a script that checks simply by attempting to connect.<br>Perhaps this can help you:<div class="codebox"><p>Code: </p><pre><code>bind pub o !ftptest ftp:testproc ftp:test {n u h c a} { if {[catch {set ftp_test [socket -async $a 21]} sockerr]} {   putserv "privmsg $n :$a is Down"   } else {   putserv "privmsg $n :$a is Up" } close $ftp_test}</code></pre></div>Edit: this should give you an idea of possible ways to do this, not an absolute answer<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4461">DragnLord</a> — Mon Jun 19, 2006 1:40 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[demond]]></name></author>
		<updated>2006-06-17T22:38:21-04:00</updated>

		<published>2006-06-17T22:38:21-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=64127#p64127</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=64127#p64127"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=64127#p64127"><![CDATA[
you need to also read the pipe to see the actual ftp server response<br><br>this is best done asynchronously using [fileevent], search the forum for "tail -f" script sample<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5056">demond</a> — Sat Jun 17, 2006 10:38 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[M4ST3R26]]></name></author>
		<updated>2006-06-17T15:04:01-04:00</updated>

		<published>2006-06-17T15:04:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=64119#p64119</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=64119#p64119"/>
		<title type="html"><![CDATA[test if FTP is online ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=64119#p64119"><![CDATA[
Hi guys, im new in tcl coding and i need help ... and my english suck so plz be patient <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br><br>I want my eggdrop to connect on FTP and check if the FTP is UP and running, if the user/password is correct.  This part is done but i want to catch connection details because my code always say Yes the ftp is up even if the login/pass isnt good ..... <br><br>there's my code ... <br><br><br><div class="codebox"><p>Code: </p><pre><code>proc check_pub {nick uhost hand chan arg} {global check_pass check_chanif {$arg !=""} {set check_strip [string map { "ftp://" "" ":" " " "@" " "} $arg]set check_FTP $argset check_address [lindex $check_strip 2]set check_port [lindex $check_strip 3]set check_username [lindex $check_strip 0]set check_password [lindex $check_strip 1]putlog "$check_FTP -- $check_username -- $check_password -- $check_address -- $check_port --"putserv "PRIVMSG $check_chan :\002\00309$nick\002\003, verrification du FTP (\002\00304 $check_address \002\003) un instant svp ..."set pipe [open "|/usr/bin/ftp -n $check_address $check_port" w]putserv "PRIVMSG $check_chan :Connection à $check_address en cours ...."puts $pipe "user $check_username $check_password"puts $pipe "put /home/m4st3r26/test.txt /test.txt"puts $pipe "quit"putserv "PRIVMSG $check_chan :Connection Reussi!"close $pipereturn 1}}</code></pre></div><br>Thanks alot !<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7885">M4ST3R26</a> — Sat Jun 17, 2006 3:04 pm</p><hr />
]]></content>
	</entry>
	</feed>
