I have a database called resources
and a table inside that database called resources
. I am trying to display some content and having some trouble. This is the code I am using:
mysql_connect('localhost', 'username', 'password', 'resources');
$query = mysql_query('SELECT * FROM resources WHERE iss = 1 ORDER BY added DESC');
$company = 'company';
while ($rows = mysql_fetch_assoc($query)) {
echo "Company: " . $rows[$company];
}