I've been seeing regex strings coming by many times now.
And it seems to be a very powerfull feature.

I have a small problem with catching / recognising URL's.
The URL's are not always being recognised. For example ftp addresses, or irc server addresses.
The below code, I use for storing the URL's that I click and adding it to an EventsLog window.

Code:
on ^1:HOTLINK:*http*:*:{
  if (http* iswm $1) return
  halt
}

on ^1:HOTLINK:*www*:*:{
  if (www* iswm $1) return
  halt
}

on 1:HOTLINK:*:*:{
  url -an $1
  write url-catcher.txt $date $time $1 ( $+ $iif($chan == $null,Private,$chan) $+ )
  echo @EventsLog $timestamp 5URL detected:
  echo @EventsLog $timestamp You just clicked: 12 $+ $1- $+ 
  echo @EventsLog -
}


Can anyone help me to improve this code?
I would like it to be a bit smarter, recognising as much as possible valid URL's. All if possible grin

Thanks in advance.

Last edited by OrionsBelt; 05/09/06 08:55 PM.