<div class="page-content">
	<div class="page-header position-relative">
		<h1>
			Client Lists <small> <i class="icon-double-angle-right"></i> With
				Status
			</small>

		</h1>

	</div>
	<!--/.page-header-->

	<div class="span7" id="8">
		<form class="form-horizontal" method="post" action="">
			<div class="control-group">
				<label class="control-label">Date Range:</label>
				<div class="controls">
					<div class="row-fluid input-prepend">

						<input class="span6" type="text" name="date[final]"
							id="id-date-range-picker-1"
							placeholder="<?php echo $clientdate['final']; ?>" /> <span
							class="add-on"> <i class="icon-calendar big"></i>
						</span> <input type="hidden" name="check" value="date">
						<button class="btn btn-small btn-purple" name="submit">Show</button>

					</div>
					<!-- .row-fluid input-prepend -->


				</div>
				<!-- /controls -->
			</div>
			<!-- /control-group -->
		</form>
	</div>
	<!-- /control-group -->


	<div class="row-fluid">
		<div class="span12">
			<!--PAGE CONTENT BEGINS-->
			<table id="example-table1"
				class="table table-striped table-bordered table-hover">
				<thead>
					<tr>
						<th>S.no</th>
						<th>Details</th>
						<th>Skype</th>
						<th>Gtalk</th>
						<th>Status</th>
						<th>Priority</th>
						<th>Created By</th>
						<th></th>
					</tr>
				</thead>

				<tbody>
										<?php
										$a = 1;
										foreach ( $query as $row ) {
											
											?>
						                  <tr>
						<td><?php echo $a;?></td>
						<td>
							<ul>
								<li><i class="icon-user"></i> <span class="text-info"> <?php echo $row['full_name'];?></span></li>
								<li><i class="icon-envelope"></i> <span class="text-info"><?php echo $row['email'];?></span></li>
								<li><i class=" icon-desktop"></i> <span class="muted"><?php echo $row['c_name'];?></span></li>
								<li><i class=" icon-home"></i> <span class="muted"><?php echo $row['address'];?></span></li>
								<li><i class=" icon-map-marker"></i> <span class="muted"><?php echo $row['country'];?></span></li>
								<li><i class=" icon-phone"></i> <span class="muted"><?php echo $row['telephone'];?></span></li>
								<li><i class=" icon-phone"></i> <span class="muted"><?php echo $row['mobile'];?></span></li>
								<li><i class=" icon-edit"></i> <span><?php echo $row['notes'];?></span></li>
							</ul>
						</td>
						<td><?php echo $row['skype'];?></td>
						<td><?php echo $row['gtalk'];?></td>
						<td>
											<?php
											
											$getclass = $db->get_col ( "status", array ("name" => $row ['sec_status'] ), 'class' );
											echo '<span class="' . $getclass [0] . '">' . $row ['sec_status'] . '</span>';
											?>
										</td>
						<td>
											<?php
											if ($row ['status'] == 0) {
												echo '<span class="label label-success arrowed">No Priority Selected</span>';
											}
											if ($row ['status'] == 1) {
												echo '<span class="label label-warning">Low Priority</span>';
											}
											if ($row ['status'] == 2) {
												echo '<span class="label label-important arrowed-in">Medium Priority</span>';
											}
											if ($row ['status'] == 3) {
												echo '<span class="label label-info arrowed-in-right arrowed">High Priority</span>';
											}
											?>
										</td>
						<td>
											<?php
											$getname = $db->get_col ( "users", array ("id" => $row ['user_id'] ), 'name' );
											$getdata = explode ( ' ', $row ['time'] );
											$updatedate = $getdata [0];
											$updatetime = $getdata [1];
											
											$createdate = explode ( ' ', $row ['created_date'] );
											
											echo $getname [0];
											echo '<br>';
											echo '<b>Added: </b>';
											echo date ( "jS F, Y", strtotime ( $createdate [0] ) ) . ',' . date ( "g:i a", strtotime ( $createdate [1] ) );
											echo '<br>';
											echo '<b>Last Updated: </b>' . date ( "jS F, Y", strtotime ( $updatedate ) ) . ' <b> , </b>' . date ( "g:i a", strtotime ( $updatetime ) );
											?>
										</td>
						<td class="td-actions">
							<div class="hidden-phone visible-desktop action-buttons">

								<a class="green"
									href="<?php echo $link->link('edit_clientdetails', Admin, '?id='.$row['id']); ?>">
									<i class="icon-pencil bigger-130"></i>
								</a> <a class="red"
									href="<?php echo $link->link('client_details',Admin, '?id='.$row['id']); ?>">
									<i class="icon-trash bigger-130"></i>
								</a>

							</div>
						</td>
					</tr>
										  <?php
											$a ++;
										}
										?>       
										

										
										</tbody>
			</table>

			<!--PAGE CONTENT ENDS-->
		</div>
		<!--/.span-->
	</div>
	<!--/.row-fluid-->
</div>
<!--/.page-content-->


</div>
<!--/.main-content-->