REBOL [
Title: "Web Page Link Displayer"
File: %weblinks.r
Date: 20-May-1999
Purpose: "Display all of the web links found on a page."
Category: [web net text 3]
]
tags: make block! 100
text: make string! 8000
html-code: [
copy tag ["<" thru ">"] (append tags tag) |
copy txt to "<" (append text txt)
]
page: read http://www.rebol.com
parse page [to "<" some html-code]
foreach tag tags [
if parse tag ["<A" thru "HREF="
[{"} copy link to {"} | copy link to ">"]
to end
][print link]
]