Controlling Firefox with Python

K

kyosohma

Hi,

I would like to be able to control Firefox through Python. I see
there's pyWinAuto, which might work if they had good documentation.
I've also messed with win32 modules, but I don't think Firefox will
work with those too nicely since it isn't a COM-based program.

I've also found some Python Firefox XUL scripting information that is
at least 2 years old and also not documented well. I really need to be
able to cycle through the tabs that are open in a current Firefox
session and search for a specifically labeled tab.

Any ideas on how to do this would be appreciated. I am using Windows
XP with Python 2.4. Thanks!

Mike
 
K

kyosohma

Hi!

See Mozlab: http://dev.hyperstruct.net/mozlab

and give a report, please.
Thank you in advance.

Michel Claveau

There seems to be some kind of weird bug with the current version of
MozLab. When I use telnet on my Windows XP box, it tries to evaluate
every character I type, which only results in lots of syntax errors. I
tried Putty in raw mode, and it works, but not well. Each line doesn't
get output to the far left. Instead, each line is dropped down one
line and tabbed over so it's one character ahead of the previous line.

I assume you think I can use Python to telnet to a running MozLab to
execute my commands? I will need to be able to do this to all the
users on a network and installing extensions on everyone's PC will be
somewhat difficult.

Mike
 
K

kyosohma

There seems to be some kind of weird bug with the current version of
MozLab. When I use telnet on my Windows XP box, it tries to evaluate
every character I type, which only results in lots of syntax errors. I
tried Putty in raw mode, and it works, but not well. Each line doesn't
get output to the far left. Instead, each line is dropped down one
line and tabbed over so it's one character ahead of the previous line.

I assume you think I can use Python to telnet to a running MozLab to
execute my commands? I will need to be able to do this to all the
users on a network and installing extensions on everyone's PC will be
somewhat difficult.

Mike

UPDATE: I can do tab traversal in Firefox using the sendkeys method. I
just need a way to read the label on the current tab or the title of
the Firefox window.

Any ideas?

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top