Ok i tried to use Pankin myspace log in

Discussion in 'Code Snippets and Tutorials' started by NHStephen, Apr 18, 2007.

  1. NHStephen

    NHStephen Level IV

    Joined:
    Jan 2, 2007
    Messages:
    1,114
    Likes Received:
    9
    but i made the code but it doesnt work anyone know the code or the url is what i need
     
  2. ZOMG

    ZOMG Level I

    Joined:
    Feb 26, 2007
    Messages:
    122
    Likes Received:
    0
    Location:
    Hipocresy Land
    Try this
    Code (Text):
    1. Dim strHTML As String
    2. strHTML = HTTPWrapper1.PostWrapper("http://login.myspace.com/index.cfm?fuseaction=login.process", "email=" & txtemail & "&password=" & txtpass)
     
  3. NHStephen

    NHStephen Level IV

    Joined:
    Jan 2, 2007
    Messages:
    1,114
    Likes Received:
    9
    aha ill try that


    EDIT: thats the same as pankin or someything


    EDIT: Again that works but idk about something
     
  4. ZOMG

    ZOMG Level I

    Joined:
    Feb 26, 2007
    Messages:
    122
    Likes Received:
    0
    Location:
    Hipocresy Land
    Code (Text):
    1. Dim strHTML As String
    2. strHTML = HTTPWrapper1.PostWrapper("http://login.myspace.com/index.cfm?fuseaction=login.process", "email=" & txtemail.Text & "&password=" & txtpass.Text)
    Mph.. now?
    Cuz is this the code
     
  5. Pankirk

    Pankirk Level III

    Joined:
    Nov 12, 2006
    Messages:
    652
    Likes Received:
    28
    Location:
    America
    Make sure you have everything named correctly 0_o and you added the wrapper and names that correctly
     
  6. NHStephen

    NHStephen Level IV

    Joined:
    Jan 2, 2007
    Messages:
    1,114
    Likes Received:
    9
    i did
     
  7. Pankirk

    Pankirk Level III

    Joined:
    Nov 12, 2006
    Messages:
    652
    Likes Received:
    28
    Location:
    America
    Ok ok.... make a textbox named "txtemail" (no quotes) and a textbox named "txtpass" (no quotes) then add your HTTPwrapper and name it "HTTP" (dont forget the moules that come with HTTP wrapper) then make a command button, double click it and put this code in it
    Code (Text):
    1. Dim strHTML As String
    2. strHTML = HTTP.PostWrapper("http://login.myspace.com/index.cfm?fuseaction=login.process", "email=" & txtemail & "&password=" & txtpass)
    that would log you in.

    now to see if you logged in or not, make a label and name it "lblusr" then make a command button. THen double click the command button and add this code
    Code (Text):
    1. Dim Stuff As String
    2. lblusr = HTTP.GetWrapper("http://home14.myspace.com/index.cfm?fuseaction=user")
    3. Stuff = GetBetween(lblusr, "Hello, ", "!")
    4. lblusr = Stuff
    and thats the code that parses thh name that your loged in as. oh yeah you will need this function, add it to the very top of your code, away from every other code.
    Code (Text):
    1. Public Function GetBetween(Source As String, start As String, Finish As String)
    2. a = InStr(1, Source, start) + Len(start)
    3.  
    4. If a = 0 Then
    5. GetBetween = ""
    6. Else
    7. B = InStr(a, Source, Finish)
    8.  
    9. If B = 0 Then
    10. GetBetween = ""
    11. Else
    12. GetBetween = Mid(Source, a, B - a)
    13. End If
    14. End If
    15.  
    16. End Function
    and if you followed it all correctyl, you would be loged in!