Michelle's Music Library

Search by artist, album, or song title:

"; print mysql_connect_error(); print "
"; } // print "connected
"; mysql_select_db('manta'); $user_query=$_GET['search']; #print 'searching'.$user_query; #$query="SELECT artist, album, title FROM iTunes WHERE artist='$user_query' OR title='$user_query' OR album='$user_query' ORDER BY album ASC"; $query="SELECT artist, album, title FROM iTunes WHERE artist REGEXP '$user_query' OR title REGEXP '$user_query' OR album REGEXP '$user_query' ORDER BY album ASC"; $result=mysql_query($query); $error=mysql_error(); if($error) { # print "

query $query
lead to error $error
"; exit; } print "\n"; $fields=array('title','artist','album') ; print ""; foreach($fields As $field) { print ""; } print "\n"; while($columns=mysql_fetch_array($result)) { print ""; foreach($fields As $field) { print ""; } print "\n"; } print "
$field
$columns[$field]
" ?>

Last Update: February 3, 2007

Valid XHTML 1.0!