Hi im doing my project in php/mysql..im doing project titled web-directory.. so i have no idea to do following task plz give me idea on this...
my problem is..
i have database in which following fileds are there
Domain-name ,Domain-TLd, place, keyword

ex: yahoo com Delhi email,search,question,answers

above keyword stores many fields which related to website..

I have search form where fields are
keywords,place
keywords can be user choice what he wants to search
place is where he wants..

ex: search : usedcars,webdesinging,website...
place: Bangalore

which search in above database as
i have used following query:

$field1 = $_GET["keyword"];
$field2 = $_GET["place"];
//*********************************
$conn = mysql_connect('localhost','root','');
mysql_select_db('webdirect',$conn);
$kt=split(" ",$field1);

while(list($key,$val)=each($kt))
{
if($val<>" " and strlen($val) > 0){$q .= " keyword like '%$val%' or ";}
// end of while
}
$q=substr($q,0,(strlen($q)-3));

// this will remove the last or from the string.s
$sql = "SELECT * FROM regtwo WHERE $q and place='$field2'";

it displays records in same order when i search everytime

if ($tr>0){

while($row = mysql_fetch_assoc($rs)) {


if($color==1){
$www='http://www.';
$sn=$www.$row['dname'].$row['dtld'];

echo "<tr bgcolor='#D4FFAA' font=><td>
<a href='$sn'>",$www.$row['dname'].$row['dtld'],</a></td><td>"
,$row['brief'],
"</td><td><img src=",$row['image']," height='50px' width='50px' /></td></tr>";


which gives results as
for ex: it matches 3 records

DOMAIN-NAME BRIEF LOGO
www.yahoo.co.in about website some image
www.google.co.in ,, ''
www.iplt20.com '' '' ''' ' ''

if you again run same query with same values in keyword & place fields you will get same order
as above

DOMAIN-NAME BRIEF LOGO
www.yahoo.co.in about website some image
www.google.co.in ,, ''
www.iplt20.com '' '' ''' ' ''

so my querry comes here?

i want to display results in different order for every try..
that means
try 1:
DOMAIN-NAME BRIEF LOGO
www.yahoo.co.in about website some image
www.google.co.in ,, ''
www.iplt20.com '' '' ''' ' ''

try 2:

DOMAIN-NAME BRIEF LOGO
www.iplt20.com '' '' ''' ' ''
www.yahoo.co.in about website some image
www.google.co.in ,, ''

you please consider that there are thousands of records to display in each search try..

ie iam displaying one by one records which satisfy condition...if we have to display all records at once it can be done by genarating ramdom numbers

so please give tip on how to display my results in different order in every try...