usersystem help

Status
Not open for further replies.

Dzetki

The Prodigal Son Returns
Jul 16, 2010
990
220
I am currently creating a social networking site for norwegian peeps, but my problem is that they can't register with their name as my system doesn't let two of that name join the site. Is there a way around this so that they can get e.g: "John Cartman" and it registers like users?id=John.Cartman" and if another one joins with the same name it becomes a little different? I also need to get it to show up at their userpage as "users?id=my.name" too, All help would be appreciated!
 

Mac

New Member
Feb 9, 2011
111
2
i have no clue on what you are requesting . please give me your source and then explain me again what you want to do ?

Edit:
if you wanna say that : "When they register with two words , between put a "."" , here you go :
PHP:
$name = str_replace(" ", ".", $_POST['name']);
also in query where you insert posted name edit :
PHP:
mysql_query("INSERT INTO users VALUES (...................., '$name')");
That means just change $_POST[name] to $name !

Edit 2:
Also , if you mean the name will stay without "." between (in the register) , but only in the profile then :
PHP:
$name = str_replace(" ", ".", $_GET['name']);
$query = mysql_query("SELECT * FROM users WHERE name='$name'");
while($a = mysql_fetch_array($query)):
# elements
endwhile;
 

Kryptos

prjRev.com
Jul 21, 2010
2,205
1,252
Then just do: user.php?id=$id
And for the $_GET part, someone would do it for you if you posted your source. Of you don't want to then ->
 
Status
Not open for further replies.

Users who are viewing this thread

Top