Get best price on Unlocked Galaxy S20 5G | ||||||||||||
|
||||||||||||
|
Wu-Name Name Generator - How It WorksThe PHP script uses two plain text files. One file holds all the adjectives.
The other consists of all of the nouns. The script reads these files into two arrays. The PHP
function Next, randomly pick an element from each array. However, I don't
want this to be totally random because your Wu-Name should not change each time you enter
generate it. Thus, I start the random number generator with a seed number, which is based on the
name entered. I use the PHP function How to Generate the Seed Number
$seed = 0; $s=0;
for ($e=1; $e<=$len; $e++) {
$chr = substr($realname,$s,$e); $seed = $seed + ord($chr)*$e; $s=$e; } How to Set Up and Pick from Arrays
// set up arrays
$adj_array = file("adjs"); $noun_array = file("nouns"); // start random number with seed srand($seed); // get random numbers $arnd = rand(0,sizeof($adj_array)-1); $nrnd = rand(0,sizeof($noun_array)-1); // create name from names and arrays $wuname = "$adj_array[$arnd] $noun_array[$nrnd]";
U.S. Name Generator is based on wu-name name generator script. It basically switches out the adjective files for files consisting of first name and last name and uses a more complex form by adding a drop-down menu to select male or female. Baby Name Generator is another name generator is based on wu-name name generator script. It switches out the adjective files for files consisting of first name and middle name and uses a more complex form by adding a drop-down menu to select boy or girl. Get the full script here (wuname.phps)
|
privacy policy || © 1997-2016. astonishinc.com All Rights Reserved. |