Jump to content

Simple Question


tpatterson1

Recommended Posts

I know this is probably really simple, but I can't figure it out.

I'm trying to select information from my database and display certain information based on the query

For example:
[code]$bareQuery = "select * from XXXXX ";
$queryall = $bareQuery.$sorted;
$resultall = MYSQL_QUERY($queryall);
$numberall = mysql_Numrows($resultall);

if ($numberall==0) {

    echo "No Records Found !";

}
else if ($numberall>1)[/code]
And then that would list whatever

But I want to display items when a certain number is reached.
I guess it's kind of hard to explain.

I'm going to have the numbers 1-5 in a database field.

If the field has a number 1 in it, i want it to pull certain information, if it has a number 2, different information, and etc.

I hope this makes sense.

Can someone please help me?
Link to comment
https://forums.phpfreaks.com/topic/27616-simple-question/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.