Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Off-topic: regular expressions Re:

From: bobr:dprc at: 23-Sep-2000 12:11

if it is a perl based regular expression to extract a URL that you want, I have a line from (the non rebol one) that will find a URL either at beginning of a line, after a space or after a * or - . It also stops the parse at a space or a tag (<) start. # Handle embedded URLs s@(^|[\-\*\s])((news|http|ftp|gopher|https)\://([^\s<]+))@$1\<A href\=\"$2" target=\"_top\"\>$2<\/A\>@go; note that @ was used as a delimiter since nearly every other punctuation char was used already in the innards. s/match/repl/go; is [s--match]@[repl--go]; a discussion about doing regular expressions can be found in the rebol email archives at ThreadHead: ThreadTail: ;# mailto: [bobr--dprc--net] At 02:31 PM 9/23/00 +0200, [mailinglists--post--com] wrote: