function isUserAdmin($username)
{
    $userStatus = getUserStatus($username);
    if (isset($userStatus)) {
        if ($userStatus == "ADMIN USER") {
            return true;
        } else {
            if ($userStatus == "NORMAL USER") {
                return false;
            }
        }
    } else {
        return null;
    }
}
Beispiel #2
0
function editUserData()
{
    $id = intval($_POST['id']);
    if ($id == 0) {
        die("error");
    }
    $origin = intval($_POST['origin']);
    $status = intval($_POST['status']);
    $getmail = $_POST['getmail'] === "true" ? 1 : 0;
    if (isset($_SESSION['superadmin']) || isset($_SESSION['admin']) && getUserStatus($id) < 2 && $status < 2) {
        echo editUser($id, $origin, $status, $_POST['username'], $_POST['password'], $_POST['email'], $_POST['fullname'], $getmail);
    } else {
        die("error");
    }
}
Beispiel #3
0
        ?>
</td>
              <td class="left"><?php 
        echo getMaxFieldLength($row['EmailAddress'], 40);
        ?>
</td>
              <td class="left"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <!--td class="center">07/06/2010</td-->
              <td class="center" id="status<?php 
        echo $row['EventAdminICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'event_admin_master', $row['EventAdminICode'], 'user', 'EventAdminICode');
        ?>
</td>
			  
              <td class="center"><a href="<?php 
        echo base_url();
        ?>
admin/user/editeventadmin/<?php 
        echo $row['EventAdminICode'];
        ?>
/"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit Event Admin" title="Edit Event Admin"/></a>&nbsp;&nbsp;&nbsp;&nbsp;
			  <img src="<?php 
        echo base_url();
Beispiel #4
0
        ?>
</td>
              <td class="left"><?php 
        echo getMaxFieldLength($row['EmailAddress'], 38);
        ?>
</td>
              <td class="left"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <!--td class="center">07/06/2010</td-->
              <td class="center" id="status<?php 
        echo $row['JudgesICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'judges_master', $row['JudgesICode'], 'Judge', 'JudgesICode');
        ?>
</td>
			  
              <td class="center"><a href="<?php 
        echo base_url();
        ?>
admin/user/editjudges/<?php 
        echo $row['JudgesICode'];
        ?>
/"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit Judge" title="Edit Judge"/></a>&nbsp;&nbsp;&nbsp;&nbsp;
			  <img src="<?php 
        echo base_url();
        echo getMaxFieldLength(ucwords($row['CompetitionName']), 25);
        ?>
</td>
              <td class="left"><?php 
        echo getDateDisplay($row['CompetitionDate']);
        ?>
</td>
              <td class="left"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <td class="center" id="status<?php 
        echo $row['CompetitionICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'competition_master', $row['CompetitionICode'], 'competition', 'CompetitionICode');
        ?>
</td>
			  <td class="center">
              <?php 
        if ($row['IsCompleted'] == 1) {
            ?>
               <a href="<?php 
            echo base_url();
            ?>
admin/user/editcompetition/<?php 
            echo $row['CompetitionICode'];
            ?>
/"><img src="<?php 
            echo base_url();
            ?>
Beispiel #6
0
<?php

header('Content-type: application/json');
chdir("..");
chdir("database");
require_once "users.php";
if (isset($_GET["email"]) and isset($_GET["password"]) and userExists((string) $_GET["email"]) and getUserStatus((string) $_GET["email"]) == "active") {
    $email = (string) $_GET["email"];
    $password = (string) $_GET["password"];
    if (checkUserLogin($email, $password)) {
        echo json_encode(array("result" => "ok"));
    } else {
        echo json_encode(array("result" => "invalidLogin"));
    }
} else {
    echo json_encode(array("result" => "missingParams"));
}
        $SectionName = $this->home->getSingleFieldValue('section_master', 'SectionName', $SingleWhere);
        ?>
                <tr class="gradeC">
                  <td class="left"><?php 
        echo getMaxFieldLength(ucwords($SectionName), 22);
        ?>
</td>
                  <td class="left"><?php 
        echo $row['TotalPercentage'];
        ?>
</td>
				  <!--td class="center" id="status<?php 
        echo $row['CompetitonResultAnalysisICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'competitionresult_analysis', $row['CompetitonResultAnalysisICode'], 'section', 'CompetitonResultAnalysisICode');
        ?>
</td-->
                  <td class="center"><img src="<?php 
        echo base_url();
        ?>
images/delete.png" border="0" width="16" height="16" alt="Delete" title="Delete" style="cursor:pointer;" onclick="deleteResultConfig('<?php 
        echo $row['CompetitonResultAnalysisICode'];
        ?>
','<?php 
        echo $row['ChampionshipICode'];
        ?>
','<?php 
        echo $row['DivisionICode'];
        ?>
');"/> </td>
function getStatus()
{
    global $response;
    global $userid;
    global $status;
    global $startOffline;
    global $processFurther;
    $sql = getUserStatus($userid);
    $query = mysql_query($sql);
    if (defined('DEV_MODE') && DEV_MODE == '1') {
        echo mysql_error();
    }
    $chat = mysql_fetch_array($query);
    if (!empty($_REQUEST['callbackfn'])) {
        $_SESSION['cometchat']['startoffline'] = 1;
    }
    if ($startOffline == 1 && empty($_SESSION['cometchat']['startoffline'])) {
        $_SESSION['cometchat']['startoffline'] = 1;
        $chat['status'] = 'offline';
        setStatus('offline');
        $_SESSION['cometchat']['cometchat_sessionvars']['buddylist'] = 0;
        $processFurther = 0;
    } else {
        if (empty($chat['status'])) {
            $chat['status'] = 'available';
        } else {
            if ($chat['status'] == 'away') {
                $chat['status'] = 'available';
                setStatus('available');
            }
            if ($chat['status'] == 'offline') {
                $processFurther = 0;
                $_SESSION['cometchat']['cometchat_sessionvars']['buddylist'] = 0;
            }
        }
    }
    if (empty($chat['message'])) {
        $chat['message'] = $status[$chat['status']];
    }
    $chat['message'] = html_entity_decode($chat['message']);
    if ($userid > 10000000) {
        $sql = "select name from cometchat_guests where id='" . $userid . "'";
        $query = mysql_query($sql);
        if (defined('DEV_MODE') && DEV_MODE == '1') {
            echo mysql_error();
        }
        $guestname = mysql_fetch_array($query);
        $guestname = $guestname['name'];
        if (function_exists('processName')) {
            $guestname = processName($guestname);
        }
        $s = array('userid' => $userid, 'message' => $chat['message'], 'status' => $chat['status'], 'guestname' => $guestname);
    } else {
        $s = array('userid' => $userid, 'message' => $chat['message'], 'status' => $chat['status']);
    }
    $response['userstatus'] = $s;
}
Beispiel #9
0
        ?>
		<tr class="gradeC">
			<td class="left"><?php 
        echo getMaxFieldLength(ucwords($row['DivisionName']), 45);
        ?>
</td>
              <td class="center"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <!--td class="center">07/06/2010</td-->
              <td class="center" id="status<?php 
        echo $row['DivisionICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'division_master', $row['DivisionICode'], 'division', 'DivisionICode');
        ?>
</td>
			  
              <td class="center">
			  <!--<img src="<?php 
        echo base_url();
        ?>
images/add_image.png" onclick="openfaceboxfordivision('addsection', '<?php 
        echo $row['DivisionICode'];
        ?>
')" border="0" width="16" height="16" alt="Add Section" title="Add Section" style="cursor:pointer;"/>
			  &nbsp;&nbsp;&nbsp;&nbsp;--><img src="<?php 
        echo base_url();
        ?>
images/edit.png" onclick="openfaceboxfordivision('editdiv', '<?php 
Beispiel #10
0
function doLoginProcess()
{
    $JSONData = json_decode(file_get_contents('php://input'));
    $userFBID = $JSONData->user_fb_id;
    $userEmail = $JSONData->user_email;
    $userName = $JSONData->name;
    $lang = $JSONData->lang;
    $isUserAlreadyRegistered = getUserStatus($userFBID);
    if ($isUserAlreadyRegistered == true) {
        // checks if user already exists or not.
        if ($userFBID != "") {
            getUserDetailsAndSendToApp($userFBID);
        }
    } else {
        // if user not exists , to create new user profile breakers,breaks table
        if ($userFBID != "" && $userEmail != "" && $userName != "") {
            createNewUserProfile($userFBID, $userEmail, $userName, $lang);
        }
    }
}
Beispiel #11
0
</td>
              <td class="left"><?php 
        echo getMaxFieldLength($row['EmailAddress'], 40);
        ?>
</td>
              
              <td class="left"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <!--td class="center">07/06/2010</td-->
              <td class="center" id="status<?php 
        echo $row['CompetitorICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'competitor_master', $row['CompetitorICode'], 'Competitor', 'CompetitorICode');
        ?>
</td>
			  <td class="center"><a href="<?php 
        echo base_url();
        ?>
admin/user/editcompetitor/<?php 
        echo $row['CompetitorICode'];
        ?>
/"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit Competitor" title="Edit Competitor"/></a>
			  <img src="<?php 
        echo base_url();
        ?>
Beispiel #12
0
        ?>
</td>
              <td class="left"><?php 
        echo substr($row['EmailAddress'], 0, 30);
        ?>
</td>
              <td class="center"><?php 
        echo getDateDisplay($row['CreatedDate']);
        ?>
</td>
			  <!--td class="center">07/06/2010</td-->
              <td class="center" id="status<?php 
        echo $row['UserICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'user_master', $row['UserICode'], 'user', 'UserICode');
        ?>
</td>
			  
              <td class="center"><a href="<?php 
        echo base_url();
        ?>
admin/user/edituser/<?php 
        echo $row['UserICode'];
        ?>
/"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit User" title="Edit User"/></a>&nbsp;&nbsp;&nbsp;&nbsp;
			  <img src="<?php 
        echo base_url();
Beispiel #13
0
			getHospitalLegaleseTimestamps("1");

		case '1.9.5':
			reportPerson($personXML, $eventShortname, $xmlFormat, $user, $pass);
			createPersonUuid($user, $pass);
			createPersonUuidBatch($number, $user, $pass);
			createNoteUuid($user, $pass);
			createNoteUuidBatch($number, $user, $pass);
			search("test", "t");
			searchWithAuth("test", "t", $user, $pass);
			getSessionTimeout();
			registerUser("testCaseUser", "*****@*****.**", "testPassword99", "testCaseGiven", "testCaseFamily");
			changeUserPassword($user, $pass, $pass);
			forgotUsername($email);
			checkUserAuth($user, $pass);
			getUserStatus($user);
			getUserGroup($user);
			getEventList();
			getEventListUser($user, $pass);
			getGroupList();
			getHospitalList();
			getHospitalData("1");
			getHospitalPolicy("1");
	}
	echo "</table><b>Note: deprecated functions are not listed/tested.</b></body>";
}




        $SectionName = $this->home->getSingleFieldValue('section_master', 'SectionName', $SingleWhere);
        ?>
                <tr class="gradeC">
                  <td class="left"><?php 
        echo getMaxFieldLength(ucwords($SectionName), 22);
        ?>
</td>
                  <td class="left"><?php 
        echo $row['PercentageValue'];
        ?>
</td>
				  <!--td class="center" id="status<?php 
        echo $row['TempResultConfigICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'temp_resultconfig', $row['TempResultConfigICode'], 'section', 'TempResultConfigICode');
        ?>
</td-->
                  <td class="center"><img src="<?php 
        echo base_url();
        ?>
images/delete.png" border="0" width="16" height="16" alt="Delete" title="Delete" style="cursor:pointer;" onclick="deleteResultConfig('<?php 
        echo $row['TempResultConfigICode'];
        ?>
');"/> </td>
                </tr>
                <?php 
    }
}
?>
              </tbody>
Beispiel #15
0
     $rHandle = fopen($sFileName, "rt");
     $sContents = fread($rHandle, filesize($sFileName));
     fclose($rHandle);
     $sContents = str_replace("#music#", getUserMusicLink(), $sContents);
     $sContents = str_replace("#video#", getUserVideoLink(), $sContents);
     $sContents = str_replace("#im#", getUserImLink($sId), $sContents);
     $sContents = str_replace("#chat#", getUserChatLink($sId), $sContents);
     $sContents = str_replace("#siteUrl#", $sRootURL, $sContents);
     $sContents = str_replace("#xmlUrl#", $sRayXmlUrl, $sContents);
     $sContents = str_replace("#desktopUrl#", $sModulesUrl . $sModule . "/", $sContents);
     break;
 case 'userAuthorize':
     $sResult = loginUser($sId, $sPassword);
     $sContents = parseXml($aXmlTemplates['result'], $sResult == TRUE_VAL ? TRUE_VAL : "msgUserAuthenticationFailure");
     if ($sResult == TRUE_VAL) {
         $sContents .= parseXml($aXmlTemplates['status'], getUserStatus($sId));
         $sContents .= getAvailableStatuses();
         saveUsers(array('online' => array(), 'offline' => array()));
     }
     break;
 case 'login':
     $sContents = parseXml($aXmlTemplates['result'], "msgUserAuthenticationFailure", FAILED_VAL);
     $sId = getIdByNick($sNick);
     $sPassword = encryptPassword($sId, $sPassword);
     if (loginUser($sNick, $sPassword, true) == TRUE_VAL) {
         $aUserInfo = getUserInfo($sId);
         login($sId, $sPassword);
         $sContents = parseXml($aXmlTemplates['result'], $sId, SUCCESS_VAL, $sPassword);
     }
     break;
 case 'logout':
Beispiel #16
0
    function competitionresult_analysistable($ChampionshipICode, $DivisionICode)
    {
        $Fields = "CompetitonResultAnalysisICode, ChampionshipICode, DivisionICode, SectionICode, TotalPercentage, IsActive";
        $WhereFieldValue = "ChampionshipICode = '" . $ChampionshipICode . "' AND DivisionICode = '" . $DivisionICode . "' AND CreatedBy = '" . $this->session->userdata('LoginUserICode') . "'";
        $ResultconfigDetails = $this->home->getParticularResults('competitionresult_analysis', $Fields, $WhereFieldValue);
        $table = '<table cellpadding="0" cellspacing="0" border="0" class="display" id="tablegrid1" width="100%">
              <thead>
                <tr>
                  <th width="34%" height="32" align="left"> Section Name </th>
                  <th width="38%" align="left" >Percentage</th>
				   <!--td width="15%" align="center" class="th_css">Status</td-->
                  <td width="13%" align="center" class="th_css">Delete</td>
                </tr>
              </thead>
              <tbody>';
        if (!empty($ResultconfigDetails)) {
            foreach ($ResultconfigDetails as $row) {
                $SectionICode = $row['SectionICode'];
                $SingleWhere = "SectionICode = '" . $row['SectionICode'] . "'";
                $SectionName = $this->home->getSingleFieldValue('section_master', 'SectionName', $SingleWhere);
                $table .= '<tr class="gradeC">
                  	<td class="left">' . getMaxFieldLength(ucwords($SectionName), 22) . '</td>
                  	<td class="left">' . $row['TotalPercentage'] . '</td>
				  	<!--td class="center" id="status' . $row['CompetitonResultAnalysisICode'] . '">' . getUserStatus($row['IsActive'], 'competitionresult_analysis', $row['CompetitonResultAnalysisICode'], 'section', 'CompetitonResultAnalysisICode') . '</td-->
                 	<td class="center"><img src="' . base_url() . 'images/delete.png" border="0" width="16" height="16" alt="Delete" title="Delete" style="cursor:pointer;" onclick="deleteResultConfig(\'' . $row['CompetitonResultAnalysisICode'] . '\', \'' . $row['ChampionshipICode'] . '\', \'' . $row['DivisionICode'] . '\');"/></td>
               		</tr>';
            }
        }
        $table .= '</tbody>
            </table>';
        echo $table;
        ?>
        <link href="<?php 
        echo base_url();
        ?>
css/themes/smoothness/jquery-ui-1.8.4.custom.css" rel="stylesheet" type="text/css" >				
		<link href="<?php 
        echo base_url();
        ?>
css/demo_table_jui.css" rel="stylesheet" type="text/css" >	
		<script type="text/javascript" src="<?php 
        echo base_url();
        ?>
js/dataTable.js"></script>
		<script language="javascript">
		$(document).ready(function() {
		oTable = $('#tablegrid1').dataTable({
			"bJQueryUI": true,
			"sPaginationType": "full_numbers",
			"aoColumns": [ null, null ]
		});
		});
		</script>
        <?php 
    }
Beispiel #17
0
    function subsectiontableforedit($SectionICode)
    {
        //load temp table data
        $WhereFieldValue = "SectionICode = '" . $SectionICode . "' AND CreatedBy = '" . $this->session->userdata('LoginUserICode') . "'";
        $OrderFiledValue = "SubsectionName ASC";
        $SubsectionDetails = $this->home->getAllDetails('subsection_master', $WhereFieldValue, $OrderFiledValue);
        $table = '<table cellpadding="0" cellspacing="0" border="0" class="display" id="tablegrid1" width="100%">
		<thead>
		<tr>
			<th width="66%" height="32" align="left">Sub Section Name </th>
			<td width="17%" align="center" class="th_css">Status</th>
			<td width="17%" align="center" class="th_css">Action</td>
		</tr>
		</thead>
		<tbody>';
        if (count($SubsectionDetails) > 0) {
            foreach ($SubsectionDetails as $row) {
                $table .= '<tr class="gradeC">
			<td class="left">' . getMaxFieldLength(ucwords($row['SubsectionName']), 30) . '</td>
			<td class="center" id="status' . $row['SubsectionICode'] . '">' . getUserStatus($row['IsActive'], 'subsection_master', $row['SubsectionICode'], 'sub-section', 'SubsectionICode') . '</td>
			<td class="center"><img src="' . base_url() . 'images/edit.png" border="0" width="16" height="16" alt="Edit Sub Section" title="Edit Sub Section" style="cursor:pointer;" onclick="editsubsectiondata(\'' . $row['SubsectionName'] . '\', \'' . $row['SubsectionICode'] . '\');"/>
			<img src="' . base_url() . 'images/delete.png" border="0" width="16" height="16" alt="Delete Sub Section" title="Delete Sub Section" style="cursor:pointer; padding-left:25px;" onclick="deleteSubSection(\'' . $row['SubsectionICode'] . '\', \'' . $SectionICode . '\');"/></td>
		</tr>';
            }
        }
        $table .= '</tbody>
		</table>';
        echo $table;
        ?>
		<link href="<?php 
        echo base_url();
        ?>
css/themes/smoothness/jquery-ui-1.8.4.custom.css" rel="stylesheet" type="text/css" >				
		<link href="<?php 
        echo base_url();
        ?>
css/demo_table_jui.css" rel="stylesheet" type="text/css" >	
		<script type="text/javascript" src="<?php 
        echo base_url();
        ?>
js/dataTable.js"></script>
		
		<script language="javascript">
		$(document).ready(function() {
		oTable = $('#tablegrid1').dataTable({
			"bJQueryUI": true,
			"sPaginationType": "full_numbers",
			"aoColumns": [ null ]
		});
		});
		</script>
		<?php 
    }
Beispiel #18
0
                    <input type="hidden" id="volumeId" name="volumeId"/>
                    <input type="hidden" id="objectCategory" name="objectCategory"/>
                    <input type="hidden" id="library" name="library"/>
                </form>
                </div>
                </div>




<?php 
// Llamado ppal
if ($_SESSION["action"] == 'reserve') {
    MenuReserves(getRecordStatus());
} else {
    $dataarr = getUserStatus();
    MenuFinalUser();
}
echo "\t\t</div>\r\n\t</div>";
include "common/footermysite.php";
echo "\t</body>\r\n</html>";
function MenuFinalUser()
{
    global $arrHttp, $msgstr, $db_path, $valortag, $lista_bases, $dataarr;
    ?>





              <div id="firstBox" class="mainBox" onmouseover="this.className = 'mainBox mainBoxHighlighted';" onmouseout="this.className = 'mainBox';">
Beispiel #19
0
	<tbody>
		<?php 
if (count($SubsectionDetails) > 0) {
    foreach ($SubsectionDetails as $row) {
        ?>
		<tr class="gradeC">
			<td class="left"><?php 
        echo getMaxFieldLength(ucwords($row['SubsectionName']), 40);
        //echo substr(ucwords($DivisionName), 0, 25);
        ?>
</td>
              <td class="center" id="status<?php 
        echo $row['TempSubsectionICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'temp_subsection', $row['TempSubsectionICode'], 'sub-section', 'TempSubsectionICode');
        ?>
</td>
			  
              <td class="center"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit Sub Section" title="Edit Sub Section" style="cursor:pointer;" onclick="editsubsectiondata('<?php 
        echo $row['SubsectionName'];
        ?>
', '<?php 
        echo $row['TempSubsectionICode'];
        ?>
');"/>
			  <img src="<?php 
        echo base_url();
Beispiel #20
0
		</tr>
		<tr>
			<td width = "90" >用户邮箱</td>
			<td style = "text-align:left;padding-left:10px;"><?php 
echo $userInfo['u_email'];
?>
</td>
		</tr>
		<tr>
			<td width = "90" >注册时间</td>
			<td style = "text-align:left;padding-left:10px;"><?php 
echo $userInfo['u_regdate'];
?>
</td>
		</tr>
		<tr>
			<td width = "90" >用户类型</td>
			<td style = "text-align:left;padding-left:10px;"><?php 
echo $userInfo['u_type'] == 0 ? "普通用户" : "管理员";
?>
</td>
		</tr>
		<tr>
			<td width = "90" >用户状态</td>
			<td style = "text-align:left;padding-left:10px;color:red;"><b><?php 
echo getUserStatus($userInfo['u_status']);
?>
</b></td>
		</tr>
	</tbody>
</table>
function getStatus()
{
    global $response;
    global $userid;
    global $status;
    global $startOffline;
    global $processFurther;
    $sql = getUserStatus($userid);
    $query = mysql_query($sql);
    if (defined('DEV_MODE') && DEV_MODE == '1') {
        echo mysql_error();
    }
    $chat = mysql_fetch_array($query);
    if ($startOffline == 1 && empty($_SESSION['cometchat']['startoffline'])) {
        $_SESSION['cometchat']['startoffline'] = 1;
        $chat['status'] = 'offline';
        setStatus('offline');
        $_SESSION['cometchat']['cometchat_sessionvars']['buddylist'] = 0;
        $processFurther = 0;
    } else {
        if (empty($chat['status'])) {
            $chat['status'] = 'available';
        } else {
            if ($chat['status'] == 'away') {
                $chat['status'] = 'available';
                setStatus('available');
            }
            if ($chat['status'] == 'offline') {
                $processFurther = 0;
                $_SESSION['cometchat']['cometchat_sessionvars']['buddylist'] = 0;
            }
        }
    }
    if (empty($chat['message'])) {
        $chat['message'] = $status[$chat['status']];
    }
    $chat['message'] = html_entity_decode($chat['message']);
    $s = array('message' => $chat['message'], 'status' => $chat['status']);
    $response['userstatus'] = $s;
}
Beispiel #22
0
	</thead>
	<tbody>
		<?php 
if (count($SubsectionDetails) > 0) {
    foreach ($SubsectionDetails as $row) {
        ?>
		<tr class="gradeC">
			<td class="left"><?php 
        echo getMaxFieldLength(ucwords($row['SubsectionName']), 40);
        ?>
</td>
              <td class="center" id="status<?php 
        echo $row['SubsectionICode'];
        ?>
"><?php 
        echo getUserStatus($row['IsActive'], 'subsection_master', $row['SubsectionICode'], 'sub-section', 'SubsectionICode');
        ?>
</td>
			  
              <td class="center"><img src="<?php 
        echo base_url();
        ?>
images/edit.png" border="0" width="16" height="16" alt="Edit Sub Section" title="Edit Sub Section" style="cursor:pointer;" onclick="editsubsectiondata('<?php 
        echo $row['SubsectionName'];
        ?>
', '<?php 
        echo $row['SubsectionICode'];
        ?>
');"/>
			  <img src="<?php 
        echo base_url();
Beispiel #23
0
<?php

session_start();
require '../functions.php';
getUserStatus($_SESSION['uid']);
if (!isset($_SESSION['loggedin'])) {
    die(header("Location: ../?return=hosts/"));
}
if (!isset($_SESSION['superadmin'])) {
    die(header("Location: ../"));
}
$error = false;
?>
<!DOCTYPE html>
<html>
    <head>
        <title><?php 
echo $_SESSION['panel'];
?>
1fx. # ServerPanel</title>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
        <link rel="stylesheet" href="../css/font-awesome.min.css">
        <link rel="stylesheet" href="../css/simple-line-icons.css">
        <link rel="stylesheet" href="../css/animate.min.css">
        <link rel="stylesheet" href="../css/whirl.css">
        <link rel="stylesheet" href="../css/bootstrap.css">
        <link rel="stylesheet" href="../css/app.css">
        <link rel="stylesheet" href="../css/select2.css">
        <link rel="stylesheet" href="../css/dataTables.bootstrap.css">
        <link id="autoloaded-stylesheet" rel="stylesheet" href="../css/<?php 
Beispiel #24
0
function getUserStatusColor($userId)
{
    $status = getUserStatus($userId);
    switch ($status) {
        case 1:
            $color = "#000000";
            break;
        case 2:
            $color = "#ff0000";
            break;
        case 3:
            $color = "#999999";
            break;
        case 4:
            $color = "#0000ff";
            break;
        case 5:
            $color = "#00ff00";
            break;
        default:
            $color = "#0000ff";
            break;
    }
    return $color;
}