New topic: 

login a user programatically to a website using login.php

<http://forums.realsoftware.com/viewtopic.php?t=32154>

       Page 1 of 1
   [ 1 post ]                 Previous topic | Next topic         Author  
Message       spacewalker           Post subject: login a user programatically 
to a website using login.phpPosted: Sat Jan 23, 2010 11:45 am                   
     
Joined: Thu Nov 08, 2007 4:59 am
Posts: 293
Location: Germany              Hello,

I need to login to website programmaticaly.

In a browser I can successfully use a URL like this:
Code:http://www.domain.com/[email protected]&passwd=123&id=456&checksum=789

This returns a session-ID and displays it in the browser.


Now I would like to do this login using RB code and save the session-ID to a 
variable.

I use the HTTPSocket control.
I have tried different variants of GET and POST methods, for example:

SessionID = 
myhttpSocket.Get("http://www.domain.com/[email protected]&passwd=123&id=456&checksum=789",0)

This returns an empty string

or

Dim login as Dictionary
login=new Dictionary

login.Value("email")="[email protected]"
login.Value("pass")="123"
login.Value("id")="456"
login.Value("checksum")="789"

myhttpSocket.SetFormData(login)
SessionID=myhttpSocket.Post ("http://www.domain.com/login.php",10)
  
This returns an empty string


Would I need the GET or POST  method of the httpsocket?
And if I have to use POST - would the use of SetFormData together with a 
dictionary be correct?

thank you     
_________________
  
                            Top           Display posts from previous: All 
posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost 
timeSubject AscendingDescending          Page 1 of 1
   [ 1 post ]     
-- 
Over 1500 classes with 29000 functions in one REALbasic plug-in collection. 
The Monkeybread Software Realbasic Plugin v9.3. 
http://www.monkeybreadsoftware.de/realbasic/plugins.shtml

[email protected]

Reply via email to