jackr1909 Posted April 8, 2011 Share Posted April 8, 2011 hi, i have a password array system and i want to be able to make a php to add a username, password and a homepage, the same as the username just at the end of a URL: The array file code looks like this: <?php //My Login Page //u //u //u //Users and Settings $domain_code = 'blogger123'; //Alpha Numeric and no space $random_num_1 = 213; //Pick a random number between 1 to 500 $random_num_2 = 754; //Pick a random number between 500 to 1000 $random_num_3 = 2; //Pick a random number between 1 to 3 //Usernames can contain alphabets, numbers, hyphens and underscore only //Set users below - Just add '' => '' with the first '' being //the username and the second '' after the => being the password. //Its an array so add an , after every password except for the //last one in the list. As shown below //Eg. $users = array( // 'user1' => 'password', // 'user2' => 'password' // ); $users = array( array('user1', 'test', '/users/1/'), array('user2', 'test', '/users/2/') array('user2', 'test', 'tusers/2/') array('user2', 'test', '/users/4/') array('user2', 'test', '/users/5/') array('user2', 'test', '/users/6/') array('user2', 'test', '/users/7/') array('user2', 'test', '/users/8/') array('user2', 'test', '/users/9/') array('user2', 'test', '/users/10/') array('user2', 'test', '/users/11/') array('user2', 'test', '/users/12/') array('user2', 'test', '/users/13/') array('user2', 'test', '/users/14/') ); ?> thanks in advance Link to comment https://forums.phpfreaks.com/topic/233142-add-username-and-password-to-array/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.