locked
Login to a MyBB Forum? RRS feed

  • Question

  • Well I'm coding a application and it requires a login to MyBB forum. Well ive  coded stuff like this before and its ussally a code like this:

      WebBrowser1.Document.GetElementById("username").SetAttribute("value", TextBox1.Text)
                WebBrowser1.Document.GetElementById("password").SetAttribute("value", TextBox2.Text)
                WebBrowser1.Document.GetElementById("login").InvokeMember("click")

     

    Well i cant find the Element ID of the MyBB forum. its in javascript i think im not 100% sure. Can someone tell me MyBB's Username & Password box's element Id & the element Id of the login button.

     

     

    Sunday, April 11, 2010 6:03 AM

Answers

  • Be aware that not every website uses the same code to handle the login.
    Success
    Cor
    Sunday, April 11, 2010 9:48 AM
  •  

    on the myBB forum I checked, button's name was 'submit' [instead of 'login']. Check source of the page you're trying to automate.

    when forum softwares are used, they are supposed to have same values in each implementation but since they are open source systems, you cant assume they would be same. << I think this was Cor's point.


    Thanks

    "Feel the Force !"
    • Marked as answer by Jeff Shan Friday, April 16, 2010 7:19 AM
    Sunday, April 11, 2010 1:03 PM

All replies

  • Be aware that not every website uses the same code to handle the login.
    Success
    Cor
    Sunday, April 11, 2010 9:48 AM
  •  

    on the myBB forum I checked, button's name was 'submit' [instead of 'login']. Check source of the page you're trying to automate.

    when forum softwares are used, they are supposed to have same values in each implementation but since they are open source systems, you cant assume they would be same. << I think this was Cor's point.


    Thanks

    "Feel the Force !"
    • Marked as answer by Jeff Shan Friday, April 16, 2010 7:19 AM
    Sunday, April 11, 2010 1:03 PM
  • All ASP related questions are supposed to go to www.aso.net

    Renee

    Sunday, April 11, 2010 1:07 PM
  • Renee, its not about asp.net.
    Thanks

    "Feel the Force !"
    Sunday, April 11, 2010 1:11 PM
  • Omie,

    The name of the thread "Login to a MyBB Forum" suggests a bulletin board which is ASP.

    Renee

    Sunday, April 11, 2010 1:20 PM
  •  

    but contents does not :-)


    Thanks

    "Feel the Force !"
    Sunday, April 11, 2010 1:24 PM
  • "Well i cant find the Element ID of the MyBB forum. its in javascript i think im not 100% sure. Can someone tell me MyBB's Username & Password box's element Id & the element Id of the login button."

    These are from the ops first post in this thread. Pray tell how this is not web related?

    Renee

    Sunday, April 11, 2010 1:29 PM
  •  

    It is web related because OP is trying to load this page into his webBrowser component and automate login on page load.

    WebBrowser's Document property provides access to HTML elements in page using DOM, that is why getElementById() method S/He's talking about.


    Thanks

    "Feel the Force !"
    Sunday, April 11, 2010 1:45 PM
  • Omie,

    You can be sure that I know what the webbrowser document property is for. I wrote knowledgeNavigator and it has a tabbed webrowser in it. To me, that answers the question. This should go to www.asp.net

    Renee

    Sunday, April 11, 2010 2:11 PM
  •  

    ok.


    Thanks

    "Feel the Force !"
    Sunday, April 11, 2010 2:16 PM
  • Omie,

    You can be sure that I know what the webbrowser document property is for. I wrote knowledgeNavigator and it has a tabbed webrowser in it. To me, that answers the question. This should go to www.asp.net

    Renee


    Will you elaborate to me what the login to a webpage using a webbrowser has to do with ASP.Net.

    It can be a straight HTML website,
    It can be an PHP website,
    It can be a SilverLight website,
    It can be an ASP website
    and much more

    None of which have any thing to do with ASP.Net which is only for ASPX.

    Microsoft has in fact no forum for that, and I assume there is not even another kind of forum or newsgroup for that, because there is no overal method to login to those pages.

    An Apache webserver has by instance not the ingegrated security from Microsoft.

     

     

     


    Success
    Cor
    Monday, April 12, 2010 7:13 AM
  • well i use this way for mybb 

     

     

                WebBrowser1.Document.GetElementById("username").SetAttribute("value", TextBox1.Text)

                WebBrowser1.Document.GetElementById("password").SetAttribute("value", TextBox2.Text)

     

     

                WebBrowser1.Document.GetElementById("submit").Focus()

                SendKeys.Send("{ENTER}")

     

    and for the site URL it should be 

    http://yoursite.con/member.php?action=login

    • Proposed as answer by MustafaVB Friday, July 23, 2010 9:57 PM
    Friday, July 23, 2010 9:26 PM