general php link mysql select values
Posted: Tue Dec 11, 2007 7:40 pm
feyd | Please use
that works perfectly, searches through my database and displays every user. however, when I click on the link of one of the displayed members, I want to display the profile information of the selected user on the linked page. So, i want to display the username or first name and etc. of the selected user (the values are in the database).
Does anybody know what I am supposed to do so I can display the profile information? All I actually need to know to code this is either the ID or username of the selected user. Then I would be able to make another simple select query like: select * from users where id/username = '$id/$username' But I don't know these values. i see that something i beeing sent through the link, but how do proceed? so, i have no clue. I would really appreciate it if somebody could help me. thanks
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
hi,
i programmed a simple register and login script. I am now working on a member script, showing all members who have registered. I got that. I did following:Code: Select all
$user_registered = mysql_query ("SELECT * from users;") or die ("error");
while ($user_registered_value = mysql_fetch_object($user_registered))
{
echo "<A HREF='mysite.php?id=$user_registered_value->id'>
$user_registered_value->username</A><BR>";
}Does anybody know what I am supposed to do so I can display the profile information? All I actually need to know to code this is either the ID or username of the selected user. Then I would be able to make another simple select query like: select * from users where id/username = '$id/$username' But I don't know these values. i see that something i beeing sent through the link, but how do proceed? so, i have no clue. I would really appreciate it if somebody could help me. thanks
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]