it's been a while since i have programmed with php..
This is the code i have on my link page
<?php
$query = "SELECT id, initial, name FROM account WHERE top ='1' ";
$result = mysql_query($query);
while($row = mysql_fetch_array($result))
{
echo " <li><a href='http://www.xxxx.com/account.php?id={$row['id']}'> {$row['name']} </a></li> ";
}
?>
so the link is pointing to account.php?id=x
now on account.php
How can i recieve the data "id, initial, name" coming from what i got on that link..
and get it to use on account.php?id=x
what code do i use to get the id from the link and print out the id data??
i know you have to use "get" function or post or sth... can you help me with the code?
i think it consist of sth like $var1 = $_GET["name"];
can i get a whole code
This is the code i have on my link page
<?php
$query = "SELECT id, initial, name FROM account WHERE top ='1' ";
$result = mysql_query($query);
while($row = mysql_fetch_array($result))
{
echo " <li><a href='http://www.xxxx.com/account.php?id={$row['id']}'> {$row['name']} </a></li> ";
}
?>
so the link is pointing to account.php?id=x
now on account.php
How can i recieve the data "id, initial, name" coming from what i got on that link..
and get it to use on account.php?id=x
what code do i use to get the id from the link and print out the id data??
i know you have to use "get" function or post or sth... can you help me with the code?
i think it consist of sth like $var1 = $_GET["name"];
can i get a whole code