Thank you for replying...
This is what I'm trying to retrieve...
function user_sub($uname)
{
$pntable = pnDBGetTables();
list($dbconn) = pnDBGetConn();
$column = &$pntable['stories_column'];
include "stories.php";
/
Fetch active laguage
*/
if (pnConfigGetVar('multilingual') == 1) {
$querylang = "AND (".$column['alanguage']."='".pnVarPrepForStore(pnUserGetLang())."' OR "
.$column['alanguage']."='') ";
} else {
$querylang = '';
}
/*
* Build up SQL
*/
$query = "SELECT ".$column['sid'].", "
.$column['title'].", "
.$column['comments'].", "
.$column['counter']." "
."FROM ".$pntable['stories']." "
."WHERE ".$column['informant']."='".pnVarPrepForStore($uname)."' "
.$querylang
."ORDER BY ".$column['sid']." DESC";
/*
* Make limited select
*/
$result = $dbconn->SelectLimit($query);
/*
* Do output
*/
OpenTable();
echo "<font class=\"pn-title\">"._SUBMISSIONS." ".pnVarPrepForDisplay($uname).": </font><br>";
while "(list('$sid, $title, $comments, $counter') = $result->fields)" {
$result->MoveNext();
If (!$title) {
$title = '- no Title -' ;
}
echo "<li><a class=\"pn-normal\" href=\"modules.php?op=modload&name=News&file=article&sid=$sid\">" . pnVarPrepForDisplay($title) . "</a><br>";
echo "<li><a class=\"pn-normal\" href=\"modules.php?op=modload&name=News&file=article&sid=$sid\">" . pnVarPrepForDisplay($comments) . "</a><br>";
echo "<li><a class=\"pn-normal\" href=\"modules.php?op=modload&name=News&file=article&sid=$sid\">" . pnVarPrepForDisplay($counter) . "</a><br>";
}
CloseTable();
}
The db schema is: sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes .....
with sid as primary
This information is all from one table. What am I doing wrong?
(This is also after all the bio information - which does fine, and the comments, which are fine, and the user login information - again fine. I just can't get the story part to show)
Thank you again!
Lady