URL Triggers?

Posted by Cuprohastes on Thu 24 Jul 2003 06:58 PM — 4 posts, 18,380 views.

#0
Short:
How do I get a regexp to highlight everything after a string, and stop highlighting on a space?


Long:
I'd like to be able to set a trigger up to fire when it sees "http" or "WWW" and highlight everything until it hits a space " "...

So in:

"This is OK of course, but really I'd like a colour version of www.bob.co.uk/gallery/my_favourite%20pic.jpg like this one http://www.fraggo.com/gallery.php??gibbergibber=1&7:stupidphpstuff <<cool huh?

It'd highlight

www.bob.co.uk/gallery/my_favourite%20pic.jpg

and

http://www.fraggo.com/gallery.php??gibbergibber=1&7:stupidphpstuff
#1
Never mind. I got it working:

(http|www).*[ ]
Australia Forum Administrator #2
I've released my URL highlighter (from a post a while back) as a plugin. You may need to amend the trigger slightly to match what you had above to make it match more general URLs.

The relevant post is at:


http://www.gammon.com.au/forum/?bbsubject_id=3018

#3
Thanks. I'm starting to really get into Mushclient - well worth the money I spent. Now I have to dig out my old Madskillz and see if I can implement my own plugins...