Page 1 of 1

5 Cent tip for today [ check online | offline website ]

Posted: Mon Mar 08, 2004 5:23 pm
by newdep
;
; checks if a list of websites is online | offline.
;

(set 'urls '(
"newlisp.org"
"www.gnu.org"
"wiki.tcl.tk"
"riki.raki.ro" ))

(define (online? www)
(if (setq checkup (net-connect www 80 ))
(begin (net-close checkup ) "Online ") "Offline"))

(dolist (url urls) ( println (online? url) ": " url))

(exit)

Posted: Thu Mar 11, 2004 3:31 am
by Ryon
Hey! This is handy. Thanks!