AutoWebClick 1.1 - freeware (build date: 01.04.2012)
AutoWebClick is application for automatization of web user interaction by executing specified set of commands from the script.
Application can be used to programmatically perform some common tasks. Example is to turn off/on wireless network by using web interface of the WLAN router (see gigaset_sx763_wlan_off.txt).
Bug Fixes and Changes (from 1.0):
- Setup was invalid)
- build with new QT 4.8
Commands are stored in script and executed sequentially. Script is in the plain text format with new line as delimiter between commands. Each command is consist of two parts: command and value delimited by TAB.
List of all supported commands:
LOAD_ABSOLUTE_URL - loads URL, e.g. "LOAD_ABSOLUTE_URL http://192.168.200.1" loads web page located at 192.168.200.1
LOAD_RELATIVE_URL - loads relative URL, e.g. home.html
FORM_FLD_FIND - finds element with CSS selector style query string, e.g. "FORM_FLD_FIND input[name='Login']" will find first input field with attribute name='Login', more attributes can be searched. E.g. input[name='wire'][value = '0'] will find first element with attribute name and value set to values specified. See details on CSS selector syntax http://www.w3.org/TR/CSS2/selector.html
FORM_FLD_SET_VALUE - sets attribute named 'value' with given value on the previously founded element (with FORM_FLD_FIND command). Commonly used to 'enter' passwords or similar, e.g. FORM_FLD_SET_VALUE my_pass will enter my_pass password into field
FORM_FLD_SET_ATTR - sets the attribute on the previously founded element. Command value is consist of name and value part delimited by '=' e.g. FORM_FLD_SET_ATTR name=wire will set previously fined element attribute 'name' to value 'wire'
WAIT 2000 - waits for specified time in miliseconds. Sometimes needed for some pages to load correctly. Wait 0 is also allowed.
Example: activate url link within web page with href='advanced.html':
//set id of the element to 'advanced_link'
var evt = document.createEvent('MouseEvents'); evt.initEvent('mousedown', true,true); document.getElementById('advanced_link').dispatchEvent(evt);
gigaset_sx763_wlan_off.txt - used to turn off WLAN on ADSL-WLAN router Siemens Gigaset SX763
gigaset_sx763_wlan_on.txt - used to turn on WLAN on ADSL-WLAN router Siemens Gigaset SX763
Command line support;
Script can be executed from command line by starting application with -execute "path to the script" parameters. E.g. AutoWebClick -execute gigaset_sx763_wlan_off.txt
Utility is freeware. Source code is copyleft although i'll appreciate if you at least mention my site: mandrilo.com if you are using any part of code. Thanks.