PDA

View Full Version : Unique profile field?


jchamber2010
07-18-2009, 09:04 PM
Is it possible to require a profile field to be unique?

I ask this here because I suspect that I'm going to have to make a plugin, or modify some vBulletin files (which I don't mind doing, as I don't ever ask vBulletin.com for support, but rather rely on communities like this for support).

Thanks

Ex.

User1 puts abc123 as FIELD4

when User2 trys to put abc123 as FIELD4 he receives an error saying you must have unique information, and to try again.

markuswarren
07-19-2009, 02:02 AM
I'm no expert but doesn't the registration screen do this on the username? If so then you could look at the register.php file and see what it is doing for the username. My guess is it's performing a database query on the username field for all user records and if there's a match, inform the user the name is taken. Thus you would do the same query, obviously substituting username for whatever your unique field is.