Viewing file: AllResearchType.php (12.52 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) | ";
echo " กรุณาทำการ Login ก่อน ";
echo "";
exit();
}
else {
/** Configuration */
include( "../configuration.php" );
require_once( $_Config_absolute_path . "/includes/framework.php" );
require_once( $_Config_absolute_path . "/include/Function.php" );
/** Create Database Object */
$dbObj = new DBConn;
/** Config Table for This Page */
$myTable = "research_tb";
$myTable1 ="research_public_tb" ;
$myTablePK = "rb.ReTyId";
//$query = " SELECT Teacher_code,First_name,Teacher_name,Teacher_lastname,Faculty_code FROM personal_tb WHERE ResearchId ='$ResearchId' ";
// $result0 = $dbObj->execQuery($query);
// $rss = $dbObj->fetchArray($result0);
/** Paging */
$page = $_GET['page'];
if( $page == "" ) { $page = 1; }
/** จำนวนข้อมูล ต่อ 1 หน้า */
$perpage = $_REQUEST['perpage'];
if( $perpage == "" ) { $perpage = 10; }
//** Where Condition */
$WHERE1 = "Year_prop=$Year_prop";
//** Parameter */
$param = "ReTyId=$ReTyId&fiscal_year_finish=$fiscal_year_finish&Teacher_code=$Teacher_code ";
} # else
?>
=$_Config_sitename;?> - ข้อมูลงานวิจัย - ข้อมูลงานวิจัยตามรายบุคคล
|
execQuery($query);
$numrows = $dbObj->_numrows;
//echo $query;
/** Paging */
$display = ( !isset ($_GET['page']) ) ? 1 : $_GET['page'];
$start = ( ($display * $limit) - $limit );
/** Paging */
if( isset($_GET['OrderBy']) ) {
$query = " SELECT * FROM research_tb rt, research_public_tb rb , research_char_tb rct WHERE rb.ReTyId='$ReTyId' and rt.Research_code = rb.Research_code and rb.Research_code=rct.Research_code and rct.Teacher_code='$Teacher_code' and rt.fiscal_year_finish='$fiscal_year_finish' ORDER BY $OrderBy $ASCDESC ";
}
elseif( !isset($_GET['OrderBy']) ) {
$query = " SELECT * FROM research_tb rt, research_public_tb rb , research_char_tb rct WHERE rb.ReTyId='$ReTyId' and rt.Research_code = rb.Research_code and rb.Research_code=rct.Research_code and rct.Teacher_code='$Teacher_code' and rt.fiscal_year_finish='$fiscal_year_finish' ORDER BY $myTablePK ASC ";
}
$query .= " LIMIT $start, $limit ";
$result = $dbObj->execQuery($query);
?>
|
freeresult($result);
/** Close the Database */
$dbObj->disconn();
/** Unset Class */
unset($dbObj);
?> |