 <div class="content-wrapper">
    <div class="container-fluid">
		
		<div class="row">
			<div class="col-lg-12">
			   <?php if(@$id >0){?>
			    <form action="<?= base_url('admin/users/update')?>" method="post" method="post" enctype="multipart/form-data">
			   <?php } else{?>
			   <form action="#" method="post" method="post" enctype="multipart/form-data">
			   <?php } ?>
			   <input type="hidden" name="id" value="<?= @$id; ?>">
			   <div class="card">
			     <div class="card-body">
				   <div class="card-title"><?= $pagetitle; ?></div>
				   <?php echo ($this->session->flashdata('form_error'));?>
				   <?php echo ($this->session->flashdata('image_error'));?>
				   <hr>
				    <form>
					 <div class="form-group row">
					  <label for="input-21" class="col-sm-2 col-form-label">Name</label>
					  <div class="col-sm-10">
						<input type="text" class="form-control" name="name" id="input-21" placeholder="Enter Name" <?php if(@$name !=''){echo "value='".@$name."'";}?>>
					  </div>
					</div>
					<div class="form-group row">
					  <label for="input-21" class="col-sm-2 col-form-label">Email</label>
					  <div class="col-sm-10">
						<input type="text" class="form-control" name="email" id="input-21" placeholder="Enter Email" <?php if(@$email !=''){echo "value='".@$email."'";}?>>
					  </div>
					</div>
					<div class="form-group row">
					  <label for="input-21" class="col-sm-2 col-form-label">Contact</label>
					  <div class="col-sm-10">
						<input type="text" class="form-control" name="contact" id="input-21" placeholder="Enter Contact" <?php if(@$contact !=''){echo "value='".@$contact."'";}?>>
					  </div>
					</div>
					<?php if(@$id==''){?>
					<div class="form-group row">
					  <label for="input-21" class="col-sm-2 col-form-label">Password</label>
					  <div class="col-sm-10">
						<input type="text" class="form-control" name="password" id="input-21" placeholder="Enter Password">
					  </div>
					</div>
					<?php } ?>
					  <div class="form-group row">
					  <label for="input-21" class="col-sm-2 col-form-label">Role Type</label>
					  <div class="col-sm-10">
							<select class="form-control single-select" name="role">
								<option>Select Role Type</option>
							<?php 		for($i=0;$i<count($accounttypeoption);$i++){
							?>
							<option value="<?= $accounttypeoption[$i]['value'] ?>" <?php if(@$role == $accounttypeoption[$i]['value']){ echo 'selected';} ?>><?= $accounttypeoption[$i]['title']; ?></option>
							<?php } ?>
							</select>
						</div>
					</div>
					
					 <div class="form-group row">
						<label for="input-23" class="col-sm-2 col-form-label">Avtar</label>
						<div class="col-sm-10">
						<input name="avtar" type="file" class="form-control" id="input-23" placeholder="Select Avtar" >
						<input name="avtarold" type="hidden" value="<?= @$avtar; ?>" >
						<?php if(@$avtar){echo "<img src='".base_url('uploads/'.@$avtar)."' width='150'>";}?>
						</div>
					  </div>
					<div class="form-group row">
					  <label for="input-24" class="col-sm-2 col-form-label">Status</label>
					  <div class="col-sm-10">
						<input type="checkbox" name="status" class="" id="activestatus" value="1" <?php if(@$status==1){echo "checked";}?>> <label for="activestatus"> Active</label>
					  </div>
					</div>
					 
					 <div class="form-group row">
					  <label class="col-sm-2 col-form-label"></label>
					  <div class="col-sm-10">
						<button type="submit" name="submit" class="btn btn-primary px-5"><i class="icon-lock"></i> Update</button>
					  </div>
					</div>
					</form>
				 </div>
			 </div>
			</form>
		</div>
	</div><!--End Row-->
	
	