require 'includes/header.php'?> if($_SERVER['REQUEST_METHOD'] === 'POST') { $image = photo_upload('image','logo'); if($image['status']) { $con->query("INSERT INTO `why_join` (`id`, `timestamp`, `image`, `title`, `content`) VALUES (NULL, CURRENT_TIMESTAMP, '".$image['file_name']."', '".$_POST['title']."', '".$_POST['content']."')"); echo ''; } else { echo ''; } } if($_GET['type'] == 'delete') { $con->query("DELETE FROM why_join where id = '".$_GET['id']."'"); echo ''; } ?>
| # | Title | Content | Delete |
|---|---|---|---|
| '.$i++.' | '.ucwords($g['title']).' | '.$g['content'].' |