We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 40122
    • 330 Posts
    I am using the Login package.

    I am using the following code from the Login RTFM to log my users out:

    <a href="[[~21? &service=logout]]" title="Logout">Logout</a>


    This works - it ends the session - but the Login form does not appear (Resource 21 contains my [[!Login]] form snippet). Only another Logout link appears as if the session has not ended.

    If I refresh the page then the Login form does appear as expected.

    Would anyone know how to fix this?

    Thanks

    This question has been answered by BobRay. See the first response.

      • 44649
      • 68 Posts
      On one of my old sites with Login I have the Login Resource ID resource in System Settings set to: 4

      With the following code on the resource(4):

      [[!Login? &redirectToPrior=`yes`]]


      Hope that helps
      • discuss.answer
        • 3749
        • 24,544 Posts
        Try adding this to the Login tag on the Login page:


        &logoutResourceId=`12`


        Change 12 to the ID of the Login page.

        PS: please don't double post.
          Did I help you? Buy me a beer
          Get my Book: MODX:The Official Guide
          MODX info for everyone: http://bobsguides.com/modx.html
          My MODX Extras
          Bob's Guides is now hosted at A2 MODX Hosting
          • 40122
          • 330 Posts
          Quote from: BobRay at Mar 06, 2015, 12:03 AM
          Try adding this to the Login tag on the Login page:


          &logoutResourceId=`12`


          Change 12 to the ID of the Login page.

          PS: please don't double post.

          Ah thanks!

          Haha weird! The duplicate post appeared after I modified this one. I have deleted.