Web Analytics Made Easy -
StatCounter how to extract records from a table - CodingForum

Announcement

Collapse
No announcement yet.

how to extract records from a table

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • how to extract records from a table

    for expample, i got one table names "songs",it contain fields of "id","name" and "url"
    how can i extract records and output it separately according to the format

    the song is "name" and its url is "url"?

  • #2
    PHP Code:

    mysql_connect
    ("host","user","password");
    mysql_select_db("db");

    $query mysql_query("SELECT * FROM songs");
    while(
    $row=mysql_fetch_array($query)){
       echo 
    $row['name'] . '<a href="'.$row['url'].'">click here</a>';
       echo 
    '<br>';

    that what ya looking for bud?
    php & asp tutorials - the birthplace - biorust - photoshop and web technologies

    Comment

    Working...
    X