| @@ 1753-1757 (lines=5) @@ | ||
| 1750 | ||
| 1751 | case 'delete': |
|
| 1752 | $storyid = 0; |
|
| 1753 | if (isset($_GET['storyid'])) { |
|
| 1754 | $storyid = (int)($_GET['storyid']); |
|
| 1755 | } elseif (isset($_POST['storyid'])) { |
|
| 1756 | $storyid = (int)($_POST['storyid']); |
|
| 1757 | } |
|
| 1758 | ||
| 1759 | if (!empty($_POST['ok'])) { |
|
| 1760 | if (empty($storyid)) { |
|
| @@ 90-96 (lines=7) @@ | ||
| 87 | ||
| 88 | // 2) Is the story published ? |
|
| 89 | $storyid = 0; |
|
| 90 | if (isset($_GET['storyid'])) { |
|
| 91 | $storyid = (int)($_GET['storyid']); |
|
| 92 | } else { |
|
| 93 | if (isset($_POST['storyid'])) { |
|
| 94 | $storyid = (int)($_POST['storyid']); |
|
| 95 | } |
|
| 96 | } |
|
| 97 | ||
| 98 | if (!empty($storyid)) { |
|
| 99 | $article = new NewsStory($storyid); |
|
| @@ 191-199 (lines=9) @@ | ||
| 188 | case 'preview': |
|
| 189 | $topic_id = (int)($_POST['topic_id']); |
|
| 190 | $xt = new NewsTopic($topic_id); |
|
| 191 | if (isset($_GET['storyid'])) { |
|
| 192 | $storyid = (int)($_GET['storyid']); |
|
| 193 | } else { |
|
| 194 | if (isset($_POST['storyid'])) { |
|
| 195 | $storyid = (int)($_POST['storyid']); |
|
| 196 | } else { |
|
| 197 | $storyid = 0; |
|
| 198 | } |
|
| 199 | } |
|
| 200 | ||
| 201 | if (!empty($storyid)) { |
|
| 202 | $story = new NewsStory($storyid); |
|
| @@ 313-321 (lines=9) @@ | ||
| 310 | $uid = 0; |
|
| 311 | } |
|
| 312 | ||
| 313 | if (isset($_GET['storyid'])) { |
|
| 314 | $storyid = (int)($_GET['storyid']); |
|
| 315 | } else { |
|
| 316 | if (isset($_POST['storyid'])) { |
|
| 317 | $storyid = (int)($_POST['storyid']); |
|
| 318 | } else { |
|
| 319 | $storyid = 0; |
|
| 320 | } |
|
| 321 | } |
|
| 322 | ||
| 323 | if (empty($storyid)) { |
|
| 324 | $story = new NewsStory(); |
|