Advertisement
wahyu_f14

publish.php

Aug 28th, 2016
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.29 KB | None | 0 0
  1. <?php
  2. include "koneksi/koneksi.php";
  3. if (isset($_GET['id'])) {
  4.   $id = $_GET['id'];
  5.   $publish = mysqli_query($db, "UPDATE berita SET status='publish' WHERE id='$id'");
  6.   if ($publish) {
  7.     header('location:data-berita.php');
  8.   }
  9. } else {
  10.   header('location:data-berita.php');
  11. }
  12. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement