Help with resquesting info from a MySQL Database

Codes here !

Moderators: macek, egami, gesf

cho@
New php-forum User
New php-forum User
Posts: 39
Joined: Tue Aug 06, 2002 8:58 am
Location: UK

Postby cho@ » Thu Aug 29, 2002 8:04 am

If i have well understood....

For that all it s happening in your request
you have your category in your URL so use the $_GET array witch content all the var that u pass with your URL

then

do something like

$cat = $_GET['Category'];

and then
if($cat)
{
$result = mysql_query("SELECT * FROM ringtone WHERE category LIKE '$cat'",$db);
while($Row=mysql_fetch_array($result))
{
your code here to display all the ringtones from the wathever category
}
}

NB: this code supose dat ur field name in ur Db for the category is 'category'

to keep ur Id one displayed just add this code

hope it will be usefull

bye
cho@


Return to “mySQL & php coding”

Who is online

Users browsing this forum: Yahoo [Bot] and 0 guests