Example #1
0
         $admin .= '</label>';
         $admin .= '<input type="submit" name="submit" value="Simpan" class="btn btn-success" />';
         $admin .= '</div></div>';
         $admin .= '</form></div>';
         $admin .= '</section>';
     }
     break;
 case 'add':
     if (isset($_POST['submit'])) {
         define("GIS_GIF", 1);
         define("GIS_JPG", 2);
         define("GIS_PNG", 3);
         define("GIS_SWF", 4);
         include "includes/hft_image.php";
         $judul = cleantext($_POST['judul']);
         $konten = hapuspetik($_POST['konten']);
         $seftitle = AuraCMSSEO($judul);
         $error = '';
         if (empty($judul)) {
             $error .= '- Error: Judul harus Diisi<br />';
         }
         if ($error != '') {
             $admin .= '<div class="alert alert-warning fade in">
                               <button data-dismiss="alert" class="close close-sm" type="button">
                                   <i class="icon-remove"></i>
                               </button>
                               <strong>Error !</strong> <br>' . $error . '.
                           </div>';
         } else {
             $files = $_FILES['gambar']['name'];
             $tmp_files = $_FILES['gambar']['tmp_name'];
Example #2
0
 if ($widgetpenulis == 2) {
     $tengah .= '<h4 class="bg">Tentang Penulis</h4>';
     $hasil = $koneksi_db->sql_query("SELECT * FROM useraura where user='******'");
     $data = $koneksi_db->sql_fetchrow($hasil);
     $user = $data['user'];
     $biodata = $data['biodata'];
     $avatar = '<img src="mod/profile/images/' . $data['avatar'] . '">';
     $avatar = $data['avatar'] == '' ? '' : '<div style="float:left; padding:3px; border:1px solid #cccccc; background:#f2f2f2; margin-right:10px;"><img src="mod/profile/images/' . $data['avatar'] . '" width="50" border="0" alt="' . $user . '" /></div>';
     $tengah .= '<div class="border"><table><tr><td>' . $avatar . '' . $biodata . '</td></tr></table></div>';
 }
 ////////////Komentar////////////////////////////////////
 if ($widgetkomentar == 2) {
     // Komentar Berita
     if ($_POST['submit'] == 'comment') {
         $nama = cleantext(hapuspetik($_POST['nama']));
         $kontenkomentar = cleantext(hapuspetik($_POST['kontenkomentar']));
         $emailkomentar = $_POST['emailkomentar'];
         $tgl = date('Y-m-d');
         $artikelid = $_POST['artikelid'];
         $ip = getenv("REMOTE_ADDR");
         checkemail($emailkomentar);
         $gfx_check = $_POST['gfx_check'];
         if ($gfx_check != $_SESSION['Var_session'] or !isset($_SESSION['Var_session'])) {
             $error .= "Error: Security Code Invalid<br />";
         }
         if (!$nama) {
             $error .= "Error: Silahkan isi Namanya<br />";
         }
         if (!$emailkomentar) {
             $error .= "Error: Silahkan isi Emailnya<br />";
         }