1) it tries to login on any web-page (it works at the first try on the most sites, except on the forum here
2) it creates a optimized login-function for the page
; #FUNCTION# =================================================================== ; Name ..........: _FF_AutoLogin ; Description ...: Auto login for HTML-forms / Generator for login-functions ; AutoIt Version : V3.3.0.0 ; Requirement(s).: FF.au3 ; Syntax ........: _FF_AutoLogin($sUserName, $sPassWord[, $sURL = ""[, $sStatus = ""[, $sSubmitMode = "keypress"[, $iMode = 0[, $iFormOffset = 0]]]]]) ; Parameter(s): .: $sUserName - ; $sPassWord - ; $sURL - Optional: (Default = "") : login page ; $sStatus - Optional: (Default = "") : Message to search on the web-page if the login was successful ; $sSubmitMode - Optional: (Default = "keypress") : if any methode fails the next in the list is tried ; | keypress ; | click ; | submit ; | off (fills only the inputs) ; $iMode - Optional: (Default = 0) : login-only ; | 1: login and returns login-function ; $iFormOffset - Optional: (Default = 0) : offset for some sites, with multiple password-inputs ; Return Value ..: Success - 1 / string (function) ; Failure - 0 ; Author(s) .....: Thorsten Willert ; Date ..........: Wed Sep 09 22:40:30 CEST 2009 ; Version .......: 3.2 ; ==============================================================================
Examples:
#include <FF.au3> _FFConnect() ; logins here at the forum and creates a login script MsgBox(0, "", _FF_AutoLogin("Username", "Password", "www.autoitscript.com/forum/index.php?app=core&module=global§ion=login", "login was successful", "submit", 1, 1)) ; login only If _FF_AutoLogin("Username", "Password", "www.autoitscript.com/forum/index.php?app=core&module=global§ion=login", "login was successful", "submit", 0, 1) Then MsgBox(0,"","Login was successful") ; login on the most other sites: If _FF_AutoLogin("Username", "Password", "http://example.com", "successful") Then ;.....
The function:
_FF_AutoLogin
Edited by Stilgar, 13 November 2009 - 08:53 PM.







