Author | Topic: imacros script -> asinet POST | |
---|---|---|
Jean-Lievin Poelman | imacros script -> asinet POST on Wed, 19 Nov 2008 10:45:55 +0100 Hello, the script mad in imacros, used to automatically logon is : /* VERSION BUILD=6071024 RECORDER=FX TAB T=1 URL GOTO=http://www.somesiite.com/login.php TAG POS=1 TYPE=INPUT:TEXT FORM=ACTION:http://www.somesite.com/login.php ATTR=NAME:username CONTENT=toto SET !ENCRYPTION NO TAG POS=1 TYPE=INPUT:PASSWORD FORM=ACTION:http://www.somesite.com/login.php ATTR=NAME:password CONTENT=titi TAG POS=1 TYPE=INPUT:SUBMIT FORM=ACTION:http://www.somesite.com/login.php ATTR=NAME:login&&VALUE:Connexion */ What string shoud I post with LoadFromUrl in order to achieve this simple task ! I'm loosing my latin. I'm sure it so easy that I don't find the solution. Thanks in advance, Jean-Liévin | |
Andreas Gehrs-Pahl | Re: imacros script -> asinet POST on Sat, 22 Nov 2008 11:36:31 -0500 Jean-Liévin, >the script mad in imacros, used to automatically logon is : I don't know anything about this "imacro", but I would guess that the following might work: LOCAL cURL := "http://www.somesite.com/login.php" LOCAL cVars := "?username=toto&password=titi&login=Connexion" LOCAL cReturn := LoadFromURL(cURL + cVars) Another option that might possibly work, could be this: LOCAL cURL := "http://toto:titi@www.somesite.com/login.php" LOCAL cVars := "?login=Connexion" LOCAL cReturn := LoadFromURL(cURL + cVars) If you can show the actual HTML file that contains this Form, it would be a little easier to determine what exactly is needed. You could also use Fiddler (or something similar) to check what your browser sends when you manually fill in the form and submit it. The above will do a Get (rather than a Post), so if the Post is required, you would have to do this: LOCAL cURL := "http://www.somesite.com/login.php" LOCAL cVars := "username=toto&password=titi&login=Connexion" LOCAL cReturn := LoadFromURL(cURL, , , , , "POST", cVars) Hope that helps. -- Andreas --- --- Andreas Gehrs-Pahl E-Mail: GPahl@CharterMI.net 415 Gute Street or: Andreas@DDPSoftware.com Owosso, MI 48867-4410 or: Andreas@Aerospace-History.net Tel: (989) 723-9927 Web Site: http://www.Aerospace-History.net --- --- |