Ns hrefs

From AOLserver Wiki
Revision as of 06:31, 19 June 2004 by WikiSysop (talk | contribs) (imported from WiKit id 575)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Man page: http://aolserver.com/docs/tcl/ns_hrefs.html


NAME

ns_hrefs - Returns URLs from anchor elements in a chunk of HTML

SYNOPSIS

ns_hrefs html

DESCRIPTION

This command finds the anchor elements (<A>) in a chunk of HTML, html, and returns a list of the URLs in those elements' href attributes.

EXAMPLES

   % set html {One good website is <A href='http://google.com/'>Google</A>.
               Another is <a href='http://www.yahoo.com'>Yahoo!</a>}
   % ns_hrefs $html
   http://google.com/ http://www.yahoo.com

NOTES

How can I instruct the Wiki to not try to format URLs in the preformatted example text?

Category Documentation - Category Core Tcl API