MySQL Forums
Forum List  »  PHP

PHP access not working right
Posted by: brendan o'donnell
Date: August 21, 2011 11:02PM

Ok, I'm trying to set up a new site to use PHP to create content from a mysql table. I'm currently trying to figure out the process by displaying the two bits of data from a recently set up table with one entry, and it simply refueses to work right, either returning absolutely nothing, or if I vary things a little, an echo of "Resource ID #2" and #3. Any thoughts on what's going wrong? Here's the code, replacing the PW with **'s and the top database name with &&'s of course.

@ $db =mysql_connect('localhost', '&&&&&&_&&&&&&', '**************');
@mysql_select_db('&&&&&&_Reports') or die ( "unable to select database");

echo "<div class=\"ShadowFrame\"><a href=\"";

$query="SELECT Adress FROM TextLinkList WHERE 1";
$result= mysql_query($query);
echo $result;
echo "\"  class=\"TextThumb\">";

$query="SELECT Title FROM TextLinkList WHERE 1";
$result= mysql_query($query);

echo $result;
echo "</a></div>";

Options: ReplyQuote


Subject
Written By
Posted
PHP access not working right
August 21, 2011 11:02PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.