/[erbot]/erbot/erbutils.el
ViewVC logotype

Diff of /erbot/erbutils.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.23 by deego, Sat Jan 8 17:53:08 2005 UTC revision 1.24 by pkazmier, Sun Jan 9 01:10:42 2005 UTC
# Line 670  lisp file, else error. " Line 670  lisp file, else error. "
670                      (erbutils-listp-proper (cdr l)))))                      (erbutils-listp-proper (cdr l)))))
671    
672    
673    (defun erbutils-html-url-p (str)
674      "Guesses if the string is a url that will yield HTML content.
675    Basically, look for any url that doesn't have any extension or
676    one that has .html, .shtml, or .htm.  Returns the str if it is
677    a valid url that might generate HTML."
678      (when (string-match "^http://[^/]+/?\\(.*\\)?$" str)
679        (let* ((path (match-string 1 str))
680               (pos (position ?. path :from-end)))
681          (when (or (null pos)
682                    (string-match "html?" (subseq path pos)))
683            str))))
684    
685    
686  ;;;###autoload  ;;;###autoload

Legend:
Removed from v.1.23  
changed lines
  Added in v.1.24

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26