Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Displaying hyperlink lists 1

Status
Not open for further replies.

walks

Technical User
May 7, 2001
203
CA
I was fooling around with PHP and MySQL and wanted to generate some lists so I didnt have to manually update each page that contains the lists. I have a few tables in my SQL for the different lists. Im just wondering how I can display the lists (as URL's) so when the user clicks on it they go to the appropriate page.

$result = mysql_query("SELECT * FROM webdesign");
while ( $row = mysql_fetch_array($result) )
{
echo ("<a href=\"" . $row["url"] . "\"" . $row["name"] . "\">
</a>") ;

}

Im a little unclear of the echo section.
 
Try this:
Code:
 echo "<a href='".$row["url"]."'>".$row["name"]."</a>" ;

--------------------------------------------------------------------------
I never set a goal because u never know whats going to happen tommorow.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top