Jump to:

5542 Posts in 1739 Topics by 1225 members

Customising the CMS

SilverStripe Forums » Customising the CMS » redirect to Login-Page

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1257 Views
  • Leo1305
    Avatar
    Community Member
    6 Posts

    redirect to Login-Page Link to this post

    Hi,

    i´ve got a page named "secured content" which is only access able for the group "school". is it possible that the page is shown for all people but if you aren´t logged in you´ll redirected to /Security/Login and back to referer ?

    thanks

    leo

  • zenmonkey
    Avatar
    Community Member
    528 Posts

    Re: redirect to Login-Page Link to this post

    If you use <% control AllChildren %> in the menu you will get links to Logged in only pages. When you click on that link it should automatically redirect you to the login page

  • Leo1305
    Avatar
    Community Member
    6 Posts

    Re: redirect to Login-Page Link to this post

    i´ve updated the navigation.ss. if i press on secured content now i get following message:

    That page is secured. Enter your credentials below and we will send you right along.

    but no login forms... in my addressline is typed http://www.momentsforever.net/Security/login !

    if i type http://www.momentsforever.net/Security/login i´m getting login forms :/

  • Dave L
    Avatar
    Community Member
    56 Posts

    Re: redirect to Login-Page Link to this post

    Do you have $Form in your main template? Security forms are rendered into $Form not, $Content, so you need to have this variable.

    1257 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.