Jump to:

23376 Posts in 18198 Topics by 2867 members

General Questions

SilverStripe Forums » General Questions » Deleted Members can still login

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Page: 1
Go to End
Author Topic: 754 Views
  • TerryMiddleton
    Avatar
    Community Member
    108 Posts

    Deleted Members can still login Link to this post

    I have manually deleted several members from the security tab on SS. However they can still login?

    Is there something else I need to do like purge the members or what?

    Also, is there a way to programmatically delete a memeber?

    Thanks,

    Terry (almost going live with my first site in SS) Middleton

  • TerryMiddleton
    Avatar
    Community Member
    108 Posts

    Re: Deleted Members can still login Link to this post

    Just found out that you can't manually delete a member. If you delete a member from a group, that member isn't *really* deleted from the database.

    After considering the scope of a delete, that sounds correct and would void the need for groups, right?

    So, the important thing to remember is if you want to restrict someone on your website, do the restriction by group and not by member.

    I do a <% if CurrentMember %>

    stuff...

    <% end_if %>

    I would need to do something like <% if CertainGroup(id) %> (I don' t exactly know the syntax of variable)

    Does anyone know how to reference a certain group the user is in on a page? I don't see that option on Built-In-Page-Controls:

    http://doc.silverstripe.com/doku.php?id=built-in-page-controls&s=page

    Let me know,

    Terry

  • Ben Gribaudo
    Avatar
    Community Member
    181 Posts

    Re: Deleted Members can still login Link to this post

    There is a ticket for this bug:
    http://open.silverstripe.com/ticket/1434

  • Howard
    Avatar
    Community Member
    215 Posts

    Re: Deleted Members can still login Link to this post

    Hi Terry,

    Sorry to hijack the thread but wondered how you went with building a registration form that then gets checked by admins before the users are added. I've got to build something similar and wondered if you had any tips

    Thanks,
    Howard

  • TerryMiddleton
    Avatar
    Community Member
    108 Posts

    Re: Deleted Members can still login Link to this post

    howardgrigg,

    Actually, I was able to do this.

    Here is what I do. I added a field called AccountEnabled and it's a boolean. When the user first registers I add them to a group and do not set the AccountEnabled. So they are disabled (0) until someone approves them (or enables the account)

    If they try to register again, I check to see if the email is in the db and what the AccountEnabled field is set to. If disabled, I tell them that their account is still being reviewed.

    If it is enabled then I send them an email with their login information.

    If they try to login, I check to see if the account is enabled or disabled. If it is disabled, I don't let them login.

    I hope this helps.

    Terry

    754 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.