<form method="POST" action="editArticle.php"> <input type="hidden" value="' . $row['ID'] . '" name="id"> <input placeholder="Title" type="text" maxlength=256 class="form-control" id="title" name="title" value="' . $row['heading'] . '"><br> <input placeholder="Smaller title for headlines" type="text" maxlength=100 class="form-control" id="smallTitle" name="smallTitle" value="' . $row['smallHeading'] . '"><br> <textarea placeholder="Content" name="content" class="form-control" rows="5">' . $row['content1'] . "\n" . $row['content2'] . '</textarea> <br><br> <input placeholder="Keywords/Tags: Separate keywords using comma" class="form-control" type="text" id="keywords" name="keywords" value="' . $row['kwords'] . '"><br> <input placeholder="Description: A few words for Google about what you\'re typing" class="form-control" type="text" id="description" name="description" value="' . $row['descript'] . '"><br> <input type="submit" value="Submit" id="submit" class="btn btn-default center-block"> </form>'; ?> </body> </html> <?php } if (isset($_GET['id']) && is_numeric($_GET['id'])) { $eArticle->verifyOwnership($_GET['id'], $author_id); if ($eArticle->er) { dispEr($eArticle->erm); } else { displayEditForm($eArticle); } } else { if (isset($_POST['id']) && is_numeric($_POST['id'])) { $eArticle->verifyOwnership($_POST['id'], $author_id); if ($eArticle->er) { dispEr($eArticle->erm); } $eArticle->updateArticle($_POST); if ($eArticle->er) { dispEr($eArticle->erm); displayEditForm($eArticle);
</div> <!-- End of slideshow div -->' . "\n"; } $textToDisp = $row['content1'] . "</p><p>" . $row['content2']; $textToDisp = str_replace("\n", "</p><p class='para'>", $textToDisp); echo "\t\t\t\t\t\t<p>" . $textToDisp . "</p>\n \n"; /*Obtain the author name and printing*/ require_once 'author/classes/editArticleClass.php'; $eArticle = new editArticle(); $authorRes = $eArticle->getAuthorIdAndName($id); if ($authorRes) { echo "<h3>Author : <a href='/author/author.php?id=" . $authorRes['author_id'] . "'>" . $authorRes['author_name'] . " </a></h3>"; } // Finished printing the author name //include 'author/classes/editArticleClass.php'; if (isset($_SESSION['author_id'])) { $eArticle->verifyOwnership($id, $_SESSION['author_id']); if (!$eArticle->er) { echo "<p> <a href='/author/editArticle.php?id={$id}'>Edit Article</a></p>"; } } // Finished printing the author name ?> <br><br> <div id="disqus_thread"></div> <script type="text/javascript"> var disqus_shortname = 'bitunofficial'; var disqus_identifier = '<?php echo $id; ?> '; /* * * DON'T EDIT BELOW THIS LINE * * */