3

Is there some way to change the current url (of current tab or an specific tab) of a running web browser (any) thru command line?

It can be any browser that run on Linux, preferably if it is light weight.

I don't mean to close and re-open the browser.

I was only able to open new tabs on browsers but not change the current url of them. I could not fast and easily find ways thru qdbus either (not that there aren't).

If some plugin alows this also, it may be ok too.

3

In Firefox you can use MozRepl addon to control Firefox via telnet. For example, to change current url of a current tab to http://v4.ident.me:

(echo "content.location.href = 'http://v4.ident.me/'"; sleep 2) | telnet localhost 4242 > /dev/null
2

install mozrepl on firefox: wiki , Download

and install fresno tools in unix: website

then use it, (i.e. Send your browser to a page: ./fresno -p http://google.com/ )

more example

  • fresno sounds interesting, may be less work than using the telnet option; I wonder when it will have a package for ubuntu at least on ppa? – Aquarius Power Jun 20 '14 at 22:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.