示例#1
0
<?php

$viewAdmin = view_admin();
$get_admin = find_admin($_SESSION['id']);
?>
<html>
<body>
	<div class="container">
		<div class="row">
			<div class="col-md-4"></div>
			<div class="col-md-4">
				<img src="photo.php?id=<?php 
echo htmlentities($_SESSION['id']);
?>
" height="250" width="250" style="border-radius:10em;border:2px solid blue;margin:15px 55px 15px;">
			</div>
			<div class="col-md-4"></div>
		</div><!-- end row of profile picture-->
		
		<div class="row">
			<div class="col-md-4"></div>
			<div class="col-md-4">
					<?php 
if ($get_admin['LABSTAT'] == 1) {
    ?>
						<div class="alert alert-success text-center" >ACTIVE</div>
					<?php 
} else {
    ?>
						<div class="alert alert-warning text-center" >INACTIVE</div>
					<?php 
示例#2
0
<?php

$q = '';
if (isset($_POST['q'])) {
    $q = trim($_POST['q']);
}
if ($q == '') {
    $search = view_admin();
} else {
    $search = search_admin($q);
}
?>

<html>
<body>
	<div class="container">
		<div class="row col-lg-12">
			<h4>
				Search Administrator
					<div class="pull-right">
					<form method="post" class="form-inline">
						<div class="input-group">
							<input type="text" name="q" value="<?php 
echo htmlentities($q);
?>
" class="form-control input-small" placeholder="Search for admin...">
						  <span class="input-group-btn">
							<button class="btn btn-default btn-large" type="submit" name="go">Go</button>
						  </span>					  
						</div><!-- /input-group -->					
					</form>