[Tutor] Webbrowser
Hello. I have recently discovered the Webbrowser module, and have started using it instead of just using IE thru win32com. But, have a few questions: 1) Is it possible to give it an adress, and if the browser gets a redirect to a different adress, I can override it? For example, I tell the browser to open a site. The browser tries, but gets redirected to a spam-site. I would therefore like to send the user somewhere else. Is it possible? 2) It doesn't seem like open(url[, new=0][, autoraise=1]) new and autoraise work with Firefox. I have tried all possible comboes, but the site is opened in a new tab in Firefox regardless. Any suggestions? Thanks in advance, Øyvind -- This email has been scanned for viruses spam by Decna as - www.decna.no Denne e-posten er sjekket for virus spam av Decna as - www.decna.no ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor
Re: [Tutor] [webbrowser] some help on an error running mozilla firefox
On 1/22/06, Rinzwind [EMAIL PROTECTED] wrote: Why does this: import webbrowser webbrowser.open('http://www.google.com;) give me this: run-mozilla.sh: Cannot execute /opt/firefox/mozilla-firefox-bin. I would assume it's a permissions error. Can you execute /opt/firefox/mozilla-firefox-bin? Is python running as a different user? -- --H.F. My penguin is bigger than yours, mister... ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor
[Tutor] [webbrowser] some help on an error running mozilla firefox
Why does this: import webbrowser webbrowser.open('http://www.google.com)give me this: run-mozilla.sh: Cannot execute /opt/firefox/mozilla-firefox-bin. Is this bacause 'webbrowser' does not know about the identification of 1.5?(I do not want to do it like this: import os os.system ('firefox http://www.google.com')bacause not all of us use firefox :) )Oh and can I, when I open a new browserwindow, force it to open in the same workspace as I am with my pythonprogram and not inside another workspace where I have a browser window open? Any enlightment would be appreciated :-) ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor
[Tutor] Webbrowser module
I am using the webbrowser module to open a URL in Mozilla. My question is what happens when I exit from Mozilla. I have a script running on a Desktop with WindowsXP and a Laptop also with windowsXP In the first case return from Mozilla is to the function containing the webbrowser command ,in the other case it restarts the whole script. mike p ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor