diff --git a/admin/index.html b/admin/index.html index 0dbc8886ae29c298ca2b6f51cb7ad5825e532050..0e70decfa268d544163204aa60862df475f9313f 100755 --- a/admin/index.html +++ b/admin/index.html @@ -39,12 +39,6 @@ Materi </a> </li> - <li class="nav-item"> - <a class="nav-link" href="#" id="notif-click"> - <span data-feather="send"></span> - Notifikasi - </a> - </li> <li class="nav-item"> <a class="nav-link" href="#" id="pengumuman-click"> <span data-feather="clipboard"></span> diff --git a/admin/js/main.js b/admin/js/main.js index 6733d52bd08dd02d5405b49fbc2689bcd1f82a50..e59ff8d913a39c5887aa9ee5b3de16eba6f5de50 100755 --- a/admin/js/main.js +++ b/admin/js/main.js @@ -12,19 +12,7 @@ $(document).ready(function(){ document.cookie = "state=home"; }); - $("a#notif-click").on("click",function(e){ - e.preventDefault(); - $.get("notifikasi.html",function(data){ - $("main").html(function(){ - $("a").removeClass("active"); - $("a#notif-click").addClass("active"); - return data; - }); - }); - document.cookie = "state=notif"; - }); - - $("a#pengumuman-click").on("click",function(e){ + $("a#pengumuman-click").on("click",function(e){ e.preventDefault(); $.get("pengumuman.html",function(data){ $("main").html(function(){ diff --git a/getAllBerita.php b/getAllBerita.php index b9581c87f8045d28b2da6082f7fa9320dfd93c19..45c24156588a90daa219b046196188fe10ba9a07 100755 --- a/getAllBerita.php +++ b/getAllBerita.php @@ -25,7 +25,7 @@ function tanggal_indo($tanggal) require 'dbConnect.php'; header('Content-Type: application/json'); -$stmt = $conn->query("SELECT `id`, `judul`, `tgl`, `foto` FROM `berita`"); +$stmt = $conn->query("SELECT `id`, `judul`, `tgl`, `foto` FROM `berita` ORDER BY `tgl` DESC"); $count = $stmt->num_rows; $res = array(); diff --git a/getAllPengumuman.php b/getAllPengumuman.php index 6407ea4989df0a85e3943e25bb49984aa9631c42..1f2cbb00ddd2f508b839d92fa7f6f3c0798f799f 100755 --- a/getAllPengumuman.php +++ b/getAllPengumuman.php @@ -12,7 +12,7 @@ require 'dbConnect.php'; -$stmt = $conn->query("SELECT * FROM `pengumuman`"); +$stmt = $conn->query("SELECT * FROM `pengumuman` ORDER BY `tanggal` DESC"); $count = $stmt->num_rows; $res = array(); while ($row = $stmt->fetch_assoc()) { diff --git a/getKmtBerita.php b/getKmtBerita.php index 684423fe98fa7cc0e84386faa0d08c0aab0fb731..a7771665d1379b049739ec434591d03fffb0b319 100755 --- a/getKmtBerita.php +++ b/getKmtBerita.php @@ -18,7 +18,7 @@ $berita_id = $_GET["id"]; $stmt = $conn->query( "SELECT kmt_berita.id AS id, tgl, komentar, user_id, berita_id, user.username AS username FROM kmt_berita LEFT OUTER JOIN user ON kmt_berita.user_id = user.id - WHERE berita_id = '" . $berita_id . "'" + WHERE berita_id = '" . $berita_id . "' ORDER BY tgl ASC " ); /* Row Counts */ diff --git a/getKmtPengumuman.php b/getKmtPengumuman.php index 1659685ed66cacf54ad9d9053cfc8d0204712910..9be076d872145d2ae26d8d47d053d6e3c140807d 100755 --- a/getKmtPengumuman.php +++ b/getKmtPengumuman.php @@ -18,7 +18,7 @@ $pengumuman_id = $_GET["id"]; $stmt = $conn->query( "SELECT kmt_pengumuman.id AS id, tgl, komentar, user_id, pengumuman_id, user.username AS username FROM kmt_pengumuman LEFT OUTER JOIN user ON kmt_pengumuman.user_id = user.id - WHERE pengumuman_id ='" . $pengumuman_id . "'" + WHERE pengumuman_id ='" . $pengumuman_id . "' ORDER BY tgl ASC " ); /* Row Counts */ diff --git a/getinfo.php b/getinfo.php new file mode 100644 index 0000000000000000000000000000000000000000..e2b4c377185a79e0f24ac2bf64f39c7ae48acc61 --- /dev/null +++ b/getinfo.php @@ -0,0 +1,3 @@ +<?php + phpinfo(); +?>