| ... | ... |
@@ -90,17 +90,17 @@ if($nid) {
|
| 90 | 90 |
$news->newBlock("newsbox");
|
| 91 | 91 |
|
| 92 | 92 |
//assign values |
| 93 |
- $news->assign("newstitle" , stripslashes(isset($stories['title']) ? $stories['title'] : null) );
|
|
| 94 |
- $news->assign("newsstory" , format_story(isset($stories['story']) ? $stories['story'] : null) );
|
|
| 95 |
- $news->assign("newsauthor", stripslashes(isset($stories['author']) ? $stories['author'] : null) );
|
|
| 96 |
- $news->assign("newsid", (isset($stories['nid']) ? $stories['nid'] : null) );
|
|
| 93 |
+ $news->assign("newstitle" , stripslashes($stories['title']) );
|
|
| 94 |
+ $news->assign("newsstory" , format_story($stories['story']) );
|
|
| 95 |
+ $news->assign("newsauthor", stripslashes($stories['author']) );
|
|
| 96 |
+ $news->assign("newsid", $stories['nid']);
|
|
| 97 | 97 |
$news->assign("oddeven", "odd");
|
| 98 | 98 |
$news->assign("skindir", $skindir);
|
| 99 |
- $news->assign("newsdate", date("$dateformat $timeformat", (isset($stories['date']) ? $stories['date'] : null) ) );
|
|
| 99 |
+ $news->assign("newsdate", date("$dateformat $timeformat", $stories['date']) );
|
|
| 100 | 100 |
if($newscomments) |
| 101 |
- $news->assign("newscomments", "<a href=\"news.php?action=newsstory&nid=".(isset($stories['nid']) ? $stories['nid'] : null)."\">".(isset($stories['comments']) ? $stories['comments'] : null)." "._COMMENTS."</a>");
|
|
| 101 |
+ $news->assign("newscomments", "<a href=\"news.php?action=newsstory&nid=".$stories['nid']."\">".(isset($stories['comments']) ? $stories['comments'] : null)." "._COMMENTS."</a>");
|
|
| 102 | 102 |
if(isADMIN && uLEVEL < 4) |
| 103 |
- $news->assign("adminoptions", "<a href=\"admin.php?action=news&form=".(isset($stories['nid']) ? $stories['nid'] : null)."\">"._EDIT."</a> | <a href=\"admin.php?action=news&delete=".(isset($stories['nid']) ? $stories['nid'] : null)."\">"._DELETE."</a>");
|
|
| 103 |
+ $news->assign("adminoptions", "<a href=\"admin.php?action=news&form=".$stories['nid']."\">"._EDIT."</a> | <a href=\"admin.php?action=news&delete=".$stories['nid']."\">"._DELETE."</a>");
|
|
| 104 | 104 |
$output .= $news->getOutputContent( ); |
| 105 | 105 |
|
| 106 | 106 |
$cquery = dbquery("SELECT COUNT(cid) FROM ".TABLEPREFIX."fanfiction_comments WHERE nid = '$nid'");
|
| ... | ... |
@@ -289,7 +289,7 @@ else {
|
| 289 | 289 |
list($type, $item) = dbrow(dbquery("SELECT type, item FROM ".TABLEPREFIX."fanfiction_reviews WHERE reviewid = '$reviewid' LIMIT 1"));
|
| 290 | 290 |
} |
| 291 | 291 |
if($type == "ST") {
|
| 292 |
- $storyquery = dbquery("SELECT s.title, s.uid, s.rid, s.sid, s.coauthors FROM ".TABLEPREFIX."fanfiction_stories as s WHERE s.sid = '$item' LIMIT 1");
|
|
| 292 |
+ $storyquery = dbquery("SELECT s.title, s.uid, s.rid, s.sid, s.coauthors FROM ".TABLEPREFIX."fanfiction_stories as s WHERE s.sid = '".(isset($item) ? $item : null)."' LIMIT 1");
|
|
| 293 | 293 |
$story = dbassoc($storyquery); |
| 294 | 294 |
$title = title_link($story); |
| 295 | 295 |
$authoruid = (isset($story['uid']) ? $story['uid'] : null); |
| ... | ... |
@@ -302,10 +302,10 @@ else {
|
| 302 | 302 |
} |
| 303 | 303 |
} |
| 304 | 304 |
else if($type == "SE") {
|
| 305 |
- $storyquery = dbquery("SELECT title, uid FROM ".TABLEPREFIX."fanfiction_series WHERE seriesid = '$item' LIMIT 1");
|
|
| 305 |
+ $storyquery = dbquery("SELECT title, uid FROM ".TABLEPREFIX."fanfiction_series WHERE seriesid = '".(isset($item) ? $item : null)."' LIMIT 1");
|
|
| 306 | 306 |
list($title, $authoruid) = dbrow($storyquery); |
| 307 | 307 |
$titletext = $title; |
| 308 |
- $title = "<a href=\"series.php?seriesid=$item\">".stripslashes($title)."</a>"; |
|
| 308 |
+ $title = "<a href=\"series.php?seriesid=".(isset($item) ? $item : null)."\">".stripslashes($title)."</a>"; |
|
| 309 | 309 |
if(empty($title && $authoruid)) accessDenied(); |
| 310 | 310 |
} |
| 311 | 311 |
else {
|
| ... | ... |
@@ -375,11 +375,11 @@ else {
|
| 375 | 375 |
} |
| 376 | 376 |
$jumpmenu = "<form name=\"jump\" action=\"\">"; |
| 377 | 377 |
$jumpmenu .= "<select name=\"sid\" onChange=\"window.location=this.options[this.selectedIndex].value\">"; |
| 378 |
- $jumpmenu .= "<option value=\"reviews.php?type=ST&item=".(isset($story['sid']) ? $story['sid'] : null).(isset($_GET['unresponded']) ? "&unresponded=1" : "")."\""; |
|
| 378 |
+ $jumpmenu .= "<option value=\"reviews.php?type=ST&item=".$story['sid'].(isset($_GET['unresponded']) ? "&unresponded=1" : "")."\""; |
|
| 379 | 379 |
if(!isset($chapid)) |
| 380 | 380 |
$jumpmenu .= " selected"; |
| 381 | 381 |
$jumpmenu .= ">"._VIEWALLREVIEWS."</option>"; |
| 382 |
- $chapquery = dbquery("SELECT inorder, title, chapid, sid FROM ".TABLEPREFIX."fanfiction_chapters WHERE sid = '".(isset($story['sid']) ? $story['sid'] : null)."' ORDER BY inorder ASC");
|
|
| 382 |
+ $chapquery = dbquery("SELECT inorder, title, chapid, sid FROM ".TABLEPREFIX."fanfiction_chapters WHERE sid = '".$story['sid']."' ORDER BY inorder ASC");
|
|
| 383 | 383 |
while($chapters = dbassoc($chapquery)) {
|
| 384 | 384 |
$jumpmenu .= "<option value=\"reviews.php?chapid=".$chapters['chapid'].(isset($_GET['unresponded']) ? "&unresponded=1" : "")."&type=ST&item=$item\""; |
| 385 | 385 |
|