ehmer
05-29-2003, 02:24 PM
What does this warning mean?
Am I asking for something in my database that apparently isn't there?
The full error is below
Warning: Supplied argument is not a valid MySQL-Link resource in C:\Program
Files\Apache Group\Apache2\htdocs\acpchn\includes\headlines.php on line 6
Warning: Supplied argument is not a valid MySQL result resource in
C:\Program Files\Apache Group\Apache2\htdocs\acpchn\includes\headlines.php
on line 7
headlines.php is...
<?php
$conn = db_connect();
$story_sql = "select * from stories
where published is not null
order by published desc";
$story_result = mysql_query($story_sql, $conn);
if (mysql_num_rows($story_result)) {
$story = mysql_fetch_array($story_result);
print "<ul>
<li>
$story[headline]
</li>
</ul>";
print "<A HREF=\"news.php\">";
print "Read more ...";
print "</A>";
}
?>
Appreciate any suggestions
David
Am I asking for something in my database that apparently isn't there?
The full error is below
Warning: Supplied argument is not a valid MySQL-Link resource in C:\Program
Files\Apache Group\Apache2\htdocs\acpchn\includes\headlines.php on line 6
Warning: Supplied argument is not a valid MySQL result resource in
C:\Program Files\Apache Group\Apache2\htdocs\acpchn\includes\headlines.php
on line 7
headlines.php is...
<?php
$conn = db_connect();
$story_sql = "select * from stories
where published is not null
order by published desc";
$story_result = mysql_query($story_sql, $conn);
if (mysql_num_rows($story_result)) {
$story = mysql_fetch_array($story_result);
print "<ul>
<li>
$story[headline]
</li>
</ul>";
print "<A HREF=\"news.php\">";
print "Read more ...";
print "</A>";
}
?>
Appreciate any suggestions
David