I’m an Opera user but I use a number of applications from the command line, and often I want to launch links from those applications into my web browser. I’ve just switched over to reading my feeds using canto (web applications are becoming decreasingly accessible these days, although I’m saving that rant for another day) which is a console-based application. This, like many other applications, allows you to specify a URL handler to use when you want to visit links.
To launch a link into a new tab in an existing Opera window, I simply used this:
opera --remote 'openURL(<url>, new-page)'
Where the <url> is the address to access; the same trick works in other programs too. For example I use irssi for IRC, with the openURL plugin, and this can do the same trick. To launch the link I simply set the http handler like this:
/set openurl_app_http opera --remote 'openURL($1, new-page)'
Since I have to look these settings up every time I want them, I thought I’d blog them for next time – and of course for anyone else who finds this useful between now and then!