We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33992 ☆ A M B ☆
    • 455 Posts
    Hi,
    I use the default template for my signup form. in this template the username field is always on focus so after loading page, scroll will go to signup form row.
    but my problem, i have put the form at the bottom of my site so after loading page the scroll go to the bottom of page.
    How can i remove the field focus?
    it’s a simple HTML question but has made problem for me.

    Thanks
    AHHP
      God loves me. 【ツ】


      MODX.ir (Persian Support)

      Boplo.ir/modx/ (Persian)
      • 26435
      • 1,193 Posts
      The weblogin snippet uses a lot of inline styles and scripts, so you have to manually remove the focus javascript from the weblogin snippet files in /assets/snippets/weblogin/

      I recently released a new weblogin snippet called WebLoginPE. It uses no inline styles and every view can be overridden with chunks. take a look at it and see if it is what you are looking for. there is a demo in my signature.

      -sD-
      Dr. Scotty Delicious, Scientist DFPA.

        Husband, Father, Brother, Son, Programmer, Atheist, Nurse, Friend, Lover, Fighter.
        All of the above... in no specific order.


        I send pointless little messages
        • 33992 ☆ A M B ☆
        • 455 Posts
        Thank you doctor! wink
        Your snippet seems very good and I’m trying it.
        but would you tell me a quick solution to solve my problem now?
        unfortunately i don’t know any about javascript


        Thank you again
        AHHP
          God loves me. 【ツ】


          MODX.ir (Persian Support)

          Boplo.ir/modx/ (Persian)
          • 26435
          • 1,193 Posts
          The code that is causing the problem is some dirty javascript that is hard coded into the weblogin snippet.
          Take a look at weblogin.inc.php at around line 89 - 91. it is the focus() directives. you can remove that entire block of code if you want and your login will still work.

          -sD-
          Dr. Scotty Delicious, Scientist DFPA.
            Husband, Father, Brother, Son, Programmer, Atheist, Nurse, Friend, Lover, Fighter.
            All of the above... in no specific order.


            I send pointless little messages
            • 33992 ☆ A M B ☆
            • 455 Posts
            Thank you, it solved.
              God loves me. 【ツ】


              MODX.ir (Persian Support)

              Boplo.ir/modx/ (Persian)