Raphaël Piéroni-3 wrote: > > Hi, > I would like to have the username equals the email for any user. > I digged into the roller sources, but i can't find a way > to customise the current behaviour. I think this is automatically > handled by acegy, > but i don't know anything in spring/acegy yet. >
This is already more or less possible. Since email should be unique and username has to be unique we could validate this behaviour (see http://www.nabble.com/is-email-address-of-a-user-in-roller-unique--tf3783455s12275.html http://www.nabble.com/is-email-address-of-a-user-in-roller-unique--tf3783455s12275.html ) Basic solution the way I see it would be to enable non alpha Numeric Chars in roller.properties (caution though the comment before this line says : # Characters to be allowed in user names (change at your own risk)) I have changed the line form username.allowedChars=A-Za-z0-9 to [EMAIL PROTECTED] Wich allows most email addresses. This enables creation of usernames that are emails. If you want both to be equal then you should use a trigger on your database to copy email to usernames (this should be done in rolleruser and userrole). The main problem being since the unique constraint does not exist on the email for now so the trigger could fail to succeed if the update attempted to set 2 usernames to the same mail resulting in different data in username and user email. This would not break roller but would require for user to login with the old email. Hope this helps :) -- View this message in context: http://www.nabble.com/Using-email-as-username-tf3790785s12275.html#a10759195 Sent from the Roller - User mailing list archive at Nabble.com.
