erbot-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Erbot-cvs] Changes to erbot/erbc.el


From: Pete Kazmier
Subject: [Erbot-cvs] Changes to erbot/erbc.el
Date: Sat, 08 Jan 2005 11:55:34 -0500

Index: erbot/erbc.el
diff -u erbot/erbc.el:1.78 erbot/erbc.el:1.79
--- erbot/erbc.el:1.78  Sat Jan  8 15:14:24 2005
+++ erbot/erbc.el       Sat Jan  8 16:41:23 2005
@@ -4151,6 +4151,19 @@
                ,@body)
            (kill-buffer ,buffer))))))
 
+(defun fsi-web-page-title (&optional site &rest args)
+  (unless site (error (format "Syntax: %s web-page-title SITE" erbnoc-char)))
+  (setq site (format "%s" site))
+  (erbnoc-with-web-page-buffer site
+    (let* ((case-fold-search t)
+           (beg (search-forward "<title>" nil t))
+           (end (search-forward "</title>" nil t)))
+      (concat "That page title is "
+              (if (and beg end)
+                  (erbutils-cleanup-whitespace 
+                   (buffer-substring beg (- end 8)))
+                "not available")))))
+
 (defun fsi-wserver (&optional site &rest args)
   (unless site (error (format "Syntax: %s wserver SITE" erbnoc-char)))
   (setq site (format "%s" site))




reply via email to

[Prev in Thread] Current Thread [Next in Thread]