Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Emulating a web browser

Tags:

c++

python

c#

.net

qt

we are tasked with basically emulating a browser to fetch webpages, looking to automate tests on different web pages. This will be used for (ideally) console-ish applications that run in the background and generate reports.

We tried going with .NET and the WatiN library, but it was built on a Marshalled IE, and so it lacked many features that we hacked in with calls to unmanaged native code, but at the end of the day IE is not thread safe nor process safe, and many of the needed features could only be implemented by changing registry values and it was just terribly unflexible.

  • Proxy support
  • JavaScript support- we have to be able to parse the actual DOM after any javascript has executed (and hopefully an event is raised to handle any ajax calls)
  • Ability to save entire contents of page including images FROM THE loaded page's CACHE to a separate location
  • ability to clear cookies/cache, get the cookies/cache, etc.
  • Ability to set headers and alter post data for any browser call
  • Process and/or thread safe would be ideal
  • And for the love of drogs, an API that isn't completely cryptic

Languages acceptable C++, C#, Python, anything that can be a simple little background application that is somewhat bearable and doesn't have a completely "untraditional" syntax like Ruby.

From my own research, and believe me I am terrible at google searches, I have heard good things about WebKit... would the Qt module QtWebKit handle all these features?

like image 229
Bad Man Avatar asked Apr 06 '10 18:04

Bad Man


People also ask

Is there an emulator for browser?

SkyEmu (The most accurate browser GBA emulator.)

What is browser emulator?

The term browser emulator refers to software that mimics the functionality of popular web browsers available in the market. For example, a Firefox emulator will provide the same look and feel of an actual Firefox browser when a website is opened on it.

Is there a browser Android emulator?

BlueStacks is arguably the most popular Android emulator for its super-fast speed and lag-free gaming experience.


1 Answers

You might try one of these:

http://code.google.com/p/spynner/

http://code.google.com/p/pywebkitgtk/

like image 87
ʇsәɹoɈ Avatar answered Sep 21 '22 01:09

ʇsәɹoɈ