View Single Post
Old 05-07-2009, 07:52 PM   #6 (permalink)
allworknoplay
The Gregarious
 
allworknoplay's Avatar
 
Join Date: Feb 2009
Location: New York
Posts: 645
Thanks: 64
allworknoplay is on a distinguished road
Default

Since I don't know exactly how your DB is structure, you could go with your second idea of storing the output into an array. Then compare what's in the array with your second output and don't show if it's in the array.

So create an array like so:

$first_list = array();


Then in your first query/output.

$cat_name = $rs['cat_name'];

Dump the names into that array.

$first_list[] = $cat_name;


Then in your second query, you can compare the value in the $first_list array and just not output anything that matches...
allworknoplay is offline  
Reply With Quote