Jump to content


Photo

empty results page


  • Please log in to reply
1 reply to this topic

#1 dadoonan

dadoonan
  • New Members
  • Pip
  • Newbie
  • 1 posts

Posted 08 April 2006 - 04:56 PM

I'm having trouble getting the correct results on a list page.

The query on the first page is pulling the name of active authors from the d/b and linking to a list page that is supposed to return essay titles by the requested author. The list page however is not returning any results.

The Author.ID, which is showing up in the URL, is being passed from the first page to the list page (http://localhost/Der...author.php?ID=5) but the list page is not accepting that variable.

This is my first php site. Sorry for so basic a question.

---------------------
List page query =

mysql_select_db($database_connDer, $connDer);
$recordID = $_GET['recordID'];
$query_GetAuthorList = "SELECT Writings.Writings_Author, Writings.Writings_Title, DATE_FORMAT(Writings_Date, '%M %D, %Y') as Writings_Date, Writings.Writings_Text, Writings.ID, Author.Autholr_Name, Author.ID FROM Writings, Author
WHERE Author.Autholr_Name = Writings.Writings_Author and
Author.ID = '$recordID'
ORDER BY Writings.Writings_Date desc";
$GetAuthorList = mysql_query($query_GetAuthorList, $connDerbyTrail) or die(mysql_error());
$row_GetAuthorList = mysql_fetch_assoc($GetAuthorList);
$totalRows_GetAuthorList = mysql_num_rows($GetAuthorList);

david


#2 earl_dc10

earl_dc10
  • Members
  • PipPipPip
  • Advanced Member
  • 71 posts

Posted 08 April 2006 - 05:06 PM

[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--] (http://localhost/Der...author.php?ID=5) but the list page is not accepting that variable.
[/quote]

if that is the exact URL (at least the ID=5 part) instead of
$recordID = $_GET['recordID'];

You'll want
$recordID = $_GET['ID'];

got a problem? Google helps many of those in need




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users