0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 3.139.236.144


Current Path : /proc/thread-self/root/var/www/html/admission/src/
Upload File :
Current File : //proc/thread-self/root/var/www/html/admission/src/resultstat.php

<?php

function loaddegres($aobj_context){
  $aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
  $univcode = $aobj_context->mobj_data['univcode'];
  $deggrp = $aobj_context->mobj_data['deggrp'];

  $querydegree = "select distinct ifnull(d.FDEGREE,'') as fdegree,ifnull(d.FDESCPN,'') as fdescpn 
  from degree d 
  inner join deggrp dg on d.fdeggrp = dg.fdeggrp
  where dg.fdeggrp = '{$deggrp}'";
// var_dump($querydegree);
// die();

 $resdegree = $aobj_context->pobj_db->GetAll($querydegree);

  if($resdegree){
      
    echo $aobj_context->mobj_output->ToJSONEnvelope($resdegree, 0, "success");
  }
  else{
    $arr['msg']="Failed to Load";
    echo $aobj_context->mobj_output->ToJSONEnvelope($arr, -1, "failure");
  }
}

function loadcollres($aobj_context){
    $aobj_context->mobj_db->SetFetchMode(ADODB_FETCH_ASSOC);
    $univcode = $aobj_context->mobj_data['univcode'];
    $degree = $aobj_context->mobj_data['deg'];

    foreach($degree as $key => $val){
        $deg .= "'".$val."',";
    }
    $degarr = substr_replace($deg ,"",-1);

    if($degree == 'all'){
        $cnd = "";
    }else{
        $cnd = "where cd.fdegree in ($degarr)";
    }
  
    $query = "select distinct ifnull(cd.fcollcode,'') as fcollcode,
    concat(c.fcollname,', ',c.ftown) as fcollname
    from college c 
    inner join colldeg cd on c.fcollcode = cd.fcollcode
    inner join degree d on d.fdegree = cd.fdegree
    $cnd";

    // var_dump($query);
    // die();

  
   $res = $aobj_context->pobj_db->GetAll($query);
  
  
    if($res){
        
      echo $aobj_context->mobj_output->ToJSONEnvelope($res, 0, "success");
    }
    else{
      $arr['msg']="Failed to Load";
      echo $aobj_context->mobj_output->ToJSONEnvelope($arr, -1, "failure");
    }
  }


?>