Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I open a website in my web browser using Python?

Tags:

python

I want to open a website in my local computer's web browser (Chrome or Internet Explorer) using Python.

open("http://google.co.kr") # something like this   

Is there a module that can do this for me?

like image 726
강병찬 Avatar asked Jul 30 '15 04:07

강병찬


People also ask

How do I open a website in a specific browser using Python?

To open a page in a specific browser, use the webbrowser. get() function to specify a particular browser.


1 Answers

The webbrowser module looks promising: https://www.youtube.com/watch?v=jU3P7qz3ZrM

import webbrowser webbrowser.open('http://google.co.kr', new=2) 
like image 188
csiu Avatar answered Oct 05 '22 23:10

csiu