Jump to content


Photo

looking for tutorial or info


  • Please log in to reply
2 replies to this topic

#1 alwaysinit

alwaysinit
  • Members
  • PipPipPip
  • Advanced Member
  • 60 posts

Posted 30 September 2006 - 02:03 AM

Does anyone know of a tutorial that will run me through creating 1000's of members profiles dynamically using PHP and MYSQL?
They won't all be created at once, just when a person joins. I lack the knowledge on how to do that.

#2 ShibSta

ShibSta
  • Members
  • PipPipPip
  • Advanced Member
  • 112 posts

Posted 30 September 2006 - 03:05 AM

When they register you store their data in the database. Then when you link to their profile you use something like:
view.php?id=213

id 213 would be the User ID in the Auto Increment column in your database.

You then use:
$result = mysql_query("SELECT * FROM users WHERE id = '$_GET[id]'");
$user = mysql_fetch_array($result);

Then you can make the layout of your profile page and simple use the array $user to display user specific data.
Lets say you have the following table columns: id, username, password, email, reg_date

If you wanted to view the username you could use:
<?php echo "Profile of $user[username]"; ?>

If you need more help look on google for "PHP MySQL Login Tutorial" and "PHP MySQL Dynamic Table"

#3 alwaysinit

alwaysinit
  • Members
  • PipPipPip
  • Advanced Member
  • 60 posts

Posted 30 September 2006 - 03:49 AM

awesome, thank you that really helps. I'll dig into it
much respek




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users