</br>
<div class="row">
	<div class=" col-md-offset-2 col-md-8">
		<div class="panel panel-default">
			<div class="panel-heading">Edit User : <?= $user->f_name.' '.$user->l_name ?></div>
			<div class="panel-body">
				<?= form_open_multipart('users/update',array('class'=>'form-horizontal')); ?>
				<?= hidden_input(array('name'=>'user_ID','value'=>$user->user_ID)) ?>
				<?= form_input_horizontal(array('name'=>'f_name','label'=>'First Name :','value'=>$user->f_name)); ?>
				<?= form_input_horizontal(array('name'=>'l_name','label'=>'Last Name :','value'=>$user->l_name)); ?>
				<?= form_input_horizontal(array('name'=>'email','label'=>'Email :','value'=>$user->email)); ?>
				<?= form_input_horizontal(array('name'=>'username','label'=>'Username :','value'=>$user->username)); ?>
				<?= form_input_horizontal(array('name'=>'password','label'=>'Password :','value'=>$user->password)); ?>
				<?= form_input_horizontal(array('name'=>'phone_no','label'=>'Phone No :','value'=>$user->phone_no)); ?>
				<?= form_textarea_horizontal(array('name'=>'address','label'=>'Address :','value'=>$user->address)); ?>
				<?= form_input_horizontal(array('name'=>'city','label'=>'City :','value'=>$user->city)); ?>
				<?= file_input_horizontal(array('name'=>'profile_img','label'=>'Profile Image :','value'=>$user->profile_img)); ?>
				<?php foreach ($user_resource_type as $resource) :
						$value = '';
						foreach($user_resource_data as $resource_data){
							if($resource_data->resource_type==$resource->user_resource_type_ID){
								$value = $resource_data->resource_data;
							} 
						}
					echo form_input_horizontal(array(
								'name'=>'user_resource['.$resource->user_resource_type_ID.']',
								'label'=> $resource->user_resource_type_name.' :',
								'value' => $value
								));
				 endforeach; ?>
				<br/>
				<div class="row">
					<div class="col-xs-11">
				<?= form_submit(array('value'=>'Save','class'=>'btn-success')); ?>
					</div>
				</div>
				<br/>
				<?= form_close(); ?>	
			</div>	
		</div>
	</div>
</div>
