Board index   FAQ   Search  
Register  Login
Board index php forum :: Database mySQL & php coding

Help with resquesting info from a MySQL Database

Codes here !

Moderators: macek, egami, gesf

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@
cho@
New php-forum User
New php-forum User
 
Posts: 39
Joined: Tue Aug 06, 2002 8:58 am
Location: UK


Return to mySQL & php coding

Who is online

Users browsing this forum: Bing [Bot] and 2 guests

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.