| @@ 88-94 (lines=7) @@ | ||
| 85 | ||
| 86 | // 2) Is the story published ? |
|
| 87 | $storyid = 0; |
|
| 88 | if (isset($_GET['storyid'])) { |
|
| 89 | $storyid = (int)$_GET['storyid']; |
|
| 90 | } else { |
|
| 91 | if (isset($_POST['storyid'])) { |
|
| 92 | $storyid = (int)$_POST['storyid']; |
|
| 93 | } |
|
| 94 | } |
|
| 95 | ||
| 96 | if (!empty($storyid)) { |
|
| 97 | $article = new NewsStory($storyid); |
|
| @@ 1997-2001 (lines=5) @@ | ||
| 1994 | ||
| 1995 | case 'delete': |
|
| 1996 | $storyid = 0; |
|
| 1997 | if (isset($_GET['storyid'])) { |
|
| 1998 | $storyid = (int)$_GET['storyid']; |
|
| 1999 | } elseif (isset($_POST['storyid'])) { |
|
| 2000 | $storyid = (int)$_POST['storyid']; |
|
| 2001 | } |
|
| 2002 | ||
| 2003 | if (!empty($_POST['ok'])) { |
|
| 2004 | if (empty($storyid)) { |
|
| @@ 189-197 (lines=9) @@ | ||
| 186 | case 'preview': |
|
| 187 | $topic_id = (int)$_POST['topic_id']; |
|
| 188 | $xt = new NewsTopic($topic_id); |
|
| 189 | if (isset($_GET['storyid'])) { |
|
| 190 | $storyid = (int)$_GET['storyid']; |
|
| 191 | } else { |
|
| 192 | if (isset($_POST['storyid'])) { |
|
| 193 | $storyid = (int)$_POST['storyid']; |
|
| 194 | } else { |
|
| 195 | $storyid = 0; |
|
| 196 | } |
|
| 197 | } |
|
| 198 | ||
| 199 | if (!empty($storyid)) { |
|
| 200 | $story = new NewsStory($storyid); |
|
| @@ 311-319 (lines=9) @@ | ||
| 308 | $uid = 0; |
|
| 309 | } |
|
| 310 | ||
| 311 | if (isset($_GET['storyid'])) { |
|
| 312 | $storyid = (int)$_GET['storyid']; |
|
| 313 | } else { |
|
| 314 | if (isset($_POST['storyid'])) { |
|
| 315 | $storyid = (int)$_POST['storyid']; |
|
| 316 | } else { |
|
| 317 | $storyid = 0; |
|
| 318 | } |
|
| 319 | } |
|
| 320 | ||
| 321 | if (empty($storyid)) { |
|
| 322 | $story = new NewsStory(); |
|