Username Generator: Difference between revisions

From UmsWiki
Jump to navigation Jump to search
Kia (talk | contribs)
No edit summary
Kia (talk | contribs)
Line 1: Line 1:
This is used to generate usernames for users in UMS.
This is used to generate usernames for users in UMS.


== Step 1 ==
==Step 1==
First you need to create some options for the setting your going to create later on.
First you need to create some options for the setting your going to create later on.


=== Options ===
===Options===


==== AddString ====
====AddString====
This option lets you add a fixed string to the username
This option lets you add a fixed string to the username


==== AutoNumber ====
====AutoNumber====
This option lets you add a number to the username.
This option lets you add a number to the username.
[[File:UsernameGenerator Options AutoNumber.jpg|none|thumb|656x656px]]


You can define the starting number and pad left to make sure it has the correct length.
You can define the starting number and pad left to make sure it has the correct length.
Line 22: Line 24:
The username number is stored in the database in the table "UsernameGenerator_Numbers"
The username number is stored in the database in the table "UsernameGenerator_Numbers"


==== DBField ====
====DBField====
This option lets you take a field from the database table ImportFromDB and use as a starting string.
This option lets you take a field from the database table ImportFromDB and use as a starting string.
[[File:UsernameGenerator Options DBField.jpg|none|thumb|656x656px]]


==== LowerCase ====
====LowerCase====
This lowercases the username.
This lowercases the username.


==== Pad ====
====Pad====
This lets you pad the username either left or right with a character you specify and a length.
This lets you pad the username either left or right with a character you specify and a length.


If you pad 4 right and the username is AB it will return AB00.
If you pad 4 right and the username is AB it will return AB00.


==== Replace ====
====Replace====
This lets you replace characters in the username with new characters or blank.
This lets you replace characters in the username with new characters or blank.
[[File:UsernameGenerator Options Replace.jpg|none|thumb|656x656px]]


If you check "Use replace from database table" it will use this feature "Database replacements".
If you check "Use replace from database table" it will use this feature "Database replacements".
[[File:UsernameGenerator Options DBReplace.jpg|none|thumb|656x656px]]
<br />


==== Replace all non alphanumeric ====
====Replace all non alphanumeric====
This will replace all characters in the username that are not within these ranges with the new string or blank
This will replace all characters in the username that are not within these ranges with the new string or blank


Line 47: Line 54:
0-9
0-9


==== Substring ====
====Substring====
This will replace a part of the username with a new string or blank.
This will replace a part of the username with a new string or blank.


==== Uppercase ====
====Uppercase====
This uppercases the username.
This uppercases the username.


== Database replacements ==
==Database replacements==
Define the strings you want to have replace with new or blank string.
Define the strings you want to have replace with new or blank string.
[[File:UsernameGenerator Database replacements.jpg|none|thumb|492x492px]]
[[File:UsernameGenerator Database replacements.jpg|none|thumb|492x492px]]
When it looks at a username it will run through all the rows and replace them if they are found.
When it looks at a username it will run through all the rows and replace them if they are found.


== Settings ==
==Settings==
This is where you create a prioritized list options. This setting is then attached to a template.
This is where you create a prioritized list options. This setting is then attached to a template.
[[File:UsernameGenerator Settings.jpg|none|thumb|383x383px]]
[[File:UsernameGenerator Settings.jpg|none|thumb|383x383px]]
<br />
<br />

Revision as of 10:57, 27 July 2021

This is used to generate usernames for users in UMS.

Step 1

First you need to create some options for the setting your going to create later on.

Options

AddString

This option lets you add a fixed string to the username

AutoNumber

This option lets you add a number to the username.


You can define the starting number and pad left to make sure it has the correct length.

If you set the start number to 1 and set pad left to 4, the number will be 0001

This number will automatically increase every time it is used to generate a new username.

If the username starts with AB then it will return AB0001

The username number is stored in the database in the table "UsernameGenerator_Numbers"

DBField

This option lets you take a field from the database table ImportFromDB and use as a starting string.

LowerCase

This lowercases the username.

Pad

This lets you pad the username either left or right with a character you specify and a length.

If you pad 4 right and the username is AB it will return AB00.

Replace

This lets you replace characters in the username with new characters or blank.


If you check "Use replace from database table" it will use this feature "Database replacements".


Replace all non alphanumeric

This will replace all characters in the username that are not within these ranges with the new string or blank

a-z

A-Z

0-9

Substring

This will replace a part of the username with a new string or blank.

Uppercase

This uppercases the username.

Database replacements

Define the strings you want to have replace with new or blank string.

When it looks at a username it will run through all the rows and replace them if they are found.

Settings

This is where you create a prioritized list options. This setting is then attached to a template.