Re: Table Search please HELP

From: Date: Fri, 07 Sep 2001 04:13:56 +0000
Subject: Re: Table Search please HELP
References: 1 2  Groups: php.windows 
Request: Send a blank email to php-windows+get-9222@lists.php.net to get a copy of this message
assuming table has column1,... column5. and you want to print all five columns. your print statement would read: print $row[column1], $row[column2]... ,$row[column5]; you are just printing one column, the TECHCONTACT one... instead of all the ones you want. there's also a print array function that would dump the entire contents of the ROW array all at once... but it's late and i'm too tired (probably lazy) to look it up... ;-) Devon wrote: > > Below is an example of my code which searches a table and prints the result, > the problem is that it only displays the TechContact where I want it to > display all the fields that associated with it in that row off the colum eg. > Mobile, AdminContact etc etc Any suggestions? > > if ($TechContact == "") > {$TechContact = '%';} > $result = mysql_query ("SELECT * FROM enet > WHERE TechContact LIKE '$TechContact%'"); > print $row["TechContact"]; > -- Leo G. Divinagracia III ldivinag@csuhayward.edu

« previous php.windows (#9222) next »