<?php
	require_once("../incorporated15/conn.php");
	require_once("../bll/f_common.php");
	require_once("../incorporated15/include/security.php");
	require_once("../bll/public_common.php");

if($_GET['eid']!=$_SESSION['id']){
	$_SESSION['user_id'] = "";
	$_SESSION['last_login'] = "";
	$_SESSION['full_name'] = "";
	$_SESSION['cpanel.php']= "";
	$_SESSION['id']= "";	
	session_destroy();
	header("Location: $base_admin");
}

$msg="";

if(isset($_POST['form_data_insert'])){
	
	$msg_class="error";

	if(strlen($_POST['mobile_1'])!=11){
		$msg = "Primary mobile no length must be 11. ";
	}

	if(strlen($_POST['bank_id'])!=6){
		$msg = "Bank ID length must be 6. ";
	}

	if($_POST['name']=="" || $_POST['fathers_name']=="" || $_POST['mothers_name']=="" || $_POST['name_bangla']=="" || $_POST['present_add']=="" || $_POST['permanent_add']=="" || $_POST['dob']=="" || $_POST['join_date']=="" || $_POST['sex']=="" || $_POST['blood_group']=="" || $_POST['nominee_name']=="" || $_POST['nominee_f_name']=="" || $_POST['nominee_m_name']=="" || $_POST['nominee_pre_address']=="" || $_POST['nominee_par_address']=="" || $_POST['nominee_percentage']=="" || $_POST['nominee_relation']=="" || $_POST['nominee_dob']=="" || $_POST['nominee_nid']=="" || $_POST['employer_name']=="" || $_POST['employer_address']=="")
		$msg.="One or more field is missed or left blank. Please fill all field properly and try again. ";


	if($_POST['mobile_1']!=''){
		$sql = "SELECT * FROM member_info WHERE mobile_1=\"$_POST[mobile_1]\"";
		$query = mysql_query($sql);
		if(mysql_num_rows($query)>0)
			$msg = "Member information (Mobile No) already exists for selected. ";
	}

	if($_POST['mobile_2']!=''){
		$sql = "SELECT * FROM member_info WHERE mobile_2=\"$_POST[mobile_2]\"";
		$query = mysql_query($sql);
		if(mysql_num_rows($query)>0)
			$msg = "Member information (Mobile No) already exists for selected. ";
	}	

	if($_POST['bank_id']!=''){
		$sql = "SELECT * FROM member_info WHERE bank_id=\"$_POST[bank_id]\"";
		$query = mysql_query($sql);
		if(mysql_num_rows($query)>0)
			$msg = "Member information (Bank ID) already exists for selected. ";
	}

	if($msg=='' && $_FILES["file_picture"]["name"]!=""){
		$extension = strtolower(@end(explode(".",$_FILES["file_picture"]["name"])));
		$allowedExts = array("jpg", "jpeg", "gif", "png");
		//Check file extension is allowed or not
		if(!in_array($extension, $allowedExts))
		$msg="Sorry invalid file type.";
		else{
			$target_file_name = img_name_with_timestamp($_FILES["file_picture"]["name"]);
			move_uploaded_file($_FILES["file_picture"]["tmp_name"], "../gallery/" . $target_file_name);
			$_POST['picture']=$target_file_name;
		}
	}
	if($msg=='' && $_FILES["file_picture_nom"]["name"]!=""){
		$extension = strtolower(@end(explode(".",$_FILES["file_picture_nom"]["name"])));
		$allowedExts = array("jpg", "jpeg", "gif", "png");
		//Check file extension is allowed or not
		if(!in_array($extension, $allowedExts))
		$msg="Sorry invalid file type.";
		else{
			$target_file_name = img_name_with_timestamp($_FILES["file_picture_nom"]["name"]);
			move_uploaded_file($_FILES["file_picture_nom"]["tmp_name"], "../gallery/" . $target_file_name);
			$_POST['picture_nom']=$target_file_name;
		}
	}

	if($msg==''){ 
		
		unset($_POST['form_data_insert']); 
		unset($_POST['hid_picture']); //unset($_POST['hid_logo']);
		unset($_POST['hid_picture_nom']); //unset($_POST['hid_logo']);

		$_POST['entry_date']=date("Y-m-d H:i:s");
		$_POST['last_update']=date("Y-m-d H:i:s");
		$_POST['entry_by']="SELF";

		if($_POST['last_promo_date']==''){
			$_POST['last_promo_date']=$_POST['join_date'];
		}

		if(save_data_into_table($_POST,"member_info")){
			$last_id=mysql_insert_id();
			$msg_class="success"; //success, error, warn
			$msg = "Member information added successfully.";
			$_POST = reset_default_values();
			header("Location: new_eo10_thanks.php");
		}

		else{
			$msg_class="error"; //success, error, warn
			$msg = "Error while inserting member information.";
		}
	}
}
elseif(!isset($_REQUEST['eid']))
{
  //default values
  $_POST = reset_default_values();
}

if(isset($_POST['form_data_update']) && strlen($_POST['form_data_update']) > 0 )
{
   $msg_class="error"; //success, error, warn
   if($_POST['name']=="" || $_POST['fathers_name']=="" || $_POST['mothers_name']=="")
     $msg='One or more field is missed or left blank. Please fill all fields properly and try again.';

   $sql = "SELECT * FROM member_info WHERE mobile_1='".make_sql_format_text($_POST['mobile_1'])."' AND bank_id='$_POST[bank_id]' AND email='$_POST[email]' AND id!=$_GET[eid]";
   $query = mysql_query($sql);
   if(mysql_num_rows($query)>0)
    $msg = "Member information is already exists.";
	   
   if($msg=='' && $_FILES["file_picture"]["name"]!="")
   {
	  //Delete existing one
	  if($_POST['hid_picture']!="")
	  @unlink("../gallery/".$_POST['hid_picture']);
	  $extension = @end(explode(".", $_FILES["file_picture"]["name"]));
	  $allowedExts = array("jpg", "jpeg", "png", "JPG", "JPEG", "PNG");
	  //Check file extension is allowed or not
	  if(!in_array($extension, $allowedExts))
		$msg.="Sorry Invalid File Type";
	  else if($_FILES["file_picture"]["size"]>$picture_size_limit){
		$msg="Photo Size is: ".number_format(($_FILES["file_picture"]["size"]/1024),2).". Photo size bigger than ".number_format(($picture_size_limit/1024),2)." KB. Please keep it less than ".number_format(($picture_size_limit/1024),2)." KB";
	  }
	  else
	  {
		$target_file_name = img_name_with_timestamp($_FILES["file_picture"]["name"]);
		move_uploaded_file($_FILES["file_picture"]["tmp_name"], "../gallery/" . $target_file_name);
		$_POST['picture']=$target_file_name;
	  }
   }
   
   if($msg=='' && $_FILES["file_picture_nom"]["name"]!="")
   {
	  //Delete existing one
	  if($_POST['hid_picture_nom']!="")
	  @unlink("../gallery/".$_POST['hid_picture_nom']);
	  $extension = @end(explode(".", $_FILES["file_picture_nom"]["name"]));
	  $allowedExts = array("jpg", "jpeg", "png", "JPG", "JPEG", "PNG");
	  //Check file extension is allowed or not
	  if(!in_array($extension, $allowedExts))
		$msg.="Sorry Invalid File Type";
	  else if($_FILES["file_picture_nom"]["size"]>$picture_size_limit){
		$msg="Photo Size is: ".number_format(($_FILES["file_picture_nom"]["size"]/1024),2).". Nominee photo size bigger than ".number_format(($picture_size_limit/1024),2)." KB. Please keep it less than ".number_format(($picture_size_limit/1024),2)." KB";
	  }
	  else
	  {
		$target_file_name = img_name_with_timestamp($_FILES["file_picture_nom"]["name"]);
		move_uploaded_file($_FILES["file_picture_nom"]["tmp_name"], "../gallery/" . $target_file_name);
		$_POST['picture_nom']=$target_file_name;
	  }
   }
	
   if($msg=='' && $_FILES["file_picture_nom_nid"]["name"]!="")
   {
	  //Delete existing one
	  if($_POST['hid_picture_nom_nid']!="")
	  @unlink("../gallery/".$_POST['hid_picture_nom_nid']);
	  $extension = @end(explode(".", $_FILES["file_picture_nom_nid"]["name"]));
	  $allowedExts = array("jpg", "jpeg", "png", "JPG", "JPEG", "PNG");
	  //Check file extension is allowed or not
	  if(!in_array($extension, $allowedExts))
		$msg.="Sorry Invalid File Type";
	  else if($_FILES["file_picture_nom_nid"]["size"]>$picture_size_limit){
		$msg="Photo Size is: ".number_format(($_FILES["file_picture_nom_nid"]["size"]/1024),2)." Nominee Nid photo size bigger than ".number_format(($picture_size_limit/1024),2)." KB. Please keep it less than ".number_format(($picture_size_limit/1024),2)." KB";
	  }
	  else
	  {
		$target_file_name = img_name_with_timestamp($_FILES["file_picture_nom_nid"]["name"]);
		move_uploaded_file($_FILES["file_picture_nom_nid"]["tmp_name"], "../gallery/" . $target_file_name);
		$_POST['picture_nom_nid']=$target_file_name;
	  }
   }

   //update data here
   if($msg=="")
   {
	 unset($_POST['form_data_update']); 
	 $condition="id=$_GET[eid]";
	 unset($_POST['hid_picture']); //unset($_POST['hid_logo']);
	 unset($_POST['hid_picture_nom']);
	 unset($_POST['hid_picture_nom_nid']);
	 $_POST['last_update']=date("Y-m-d H:i:s");
	 $_POST['updated_by']=$_SESSION['user_id'];  
   	 /*if($_POST['last_promo_date']==''){
			$_POST['last_promo_date']=$_POST['join_date'];
	 }*/
	 if(update_data_into_table($_POST,"member_info",$condition))
	 {
		 $msg.= "Successfully Updated.";
		 $msg_class="success"; //success, error, warn
	  }
	  else
	  {
		  $msg.= "Error while update.";
		  $msg_class="error"; //success, error, warn
	   }
   }
   $button="form_data_update";
   $lbl="Update";
}

if(isset($_REQUEST['eid']) && strlen($_REQUEST['eid']) > 0 && !isset($_POST['form_data_update']))
{
 $head="Edit Member Information";
 $rs_result=mysql_query("SELECT * FROM member_info WHERE id=$_REQUEST[eid]");
 $_POST=mysql_fetch_array($rs_result);
}

function reset_default_values()
{
  $default_values = array('form_serial_no'=>'', 'name'=>'', 'name_bangla'=>'', 'fathers_name'=>'', 'mothers_name'=>'', 'designation'=>'', 'bank_id'=>'', 'join_date'=>'', 'last_promo_date'=>'', 'dob'=>'', 'blood_group'=>'', 'pro_certificate'=>'', 'last_pomo_date'=>'', 'present_add'=>'', 'permanent_add'=>'', 'mobile_1'=>'', 'mobile_2'=>'', 'email'=>'', 'branch_manager'=>'', 'expertise_sector'=>'', 'pre_post_code'=>'', 'per_post_code'=>'', 'pre_district'=>'', 'per_district'=>'', 'pre_police_station'=>'', 'per_police_station'=>'', 'pre_post_office'=>'', 'per_post_office'=>'', 'sex'=>'', 'nominee_name'=>'', 'nominee_f_name'=>'', 'nominee_m_name'=>'', 'nominee_pre_address'=>'', 'nominee_par_address'=>'', 'nominee_percentage'=>'', 'nominee_relation'=>'', 'nominee_dob'=>'', 'nominee_nid'=>'', 'employer_name'=>'', 'employer_address'=>'');
  return $default_values;
}

?>
  <!--A Design by W3layouts
   Author: W3layout
   Author URL: http://w3layouts.com
   License: Creative Commons Attribution 3.0 Unported
   License URL: http://creativecommons.org/licenses/by/3.0/
   -->
<!DOCTYPE html>
<html lang="en">
   
<!-- Mirrored from demo.w3layouts.com/demos_new/template_demo/04-08-2018/summer_camp_form-demo_Free/1603175437/web/index.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 22 May 2019 12:50:09 GMT -->
<!-- Added by HTTrack --><meta http-equiv="content-type" content="text/html;charset=UTF-8" /><!-- /Added by HTTrack -->
<head>
      <title>iNCORPORATED : Personal Information Update</title>
      <!-- Meta tags -->
      <meta name="viewport" content="width=device-width, initial-scale=1" />
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
      <meta name="keywords" content="Summer Camp Form Responsive Widget, Audio and Video players, Login Form Web Template, Flat Pricing Tables, Flat Drop-Downs, Sign-Up Web Templates, Flat Web Templates, Login Sign-up Responsive Web Template, Smartphone Compatible Web Template, Free Web Designs for Nokia, Samsung, LG, Sony Ericsson, Motorola Web Design"
         />
      <script>
         addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false); function hideURLbar(){ window.scrollTo(0,1); }
      </script>
      <!-- Meta tags -->
      <!-- Calendar -->
      <link rel="stylesheet" href="css/jquery-ui.css" />
      <!-- //Calendar -->
      <!--stylesheets-->
      <link href="css/style.css" rel='stylesheet' type='text/css' media="all">
      <!--//style sheet end here-->
      <!-- Google fonts here-->
      <link href="http://fonts.googleapis.com/css?family=Barlow:300,400,500" rel="stylesheet">
      <link href="http://fonts.googleapis.com/css?family=Josefin+Sans:300,400,600,700" rel="stylesheet">
      <!--//Google fonts here-->
      <link rel="stylesheet" href="css/jquery-ui.css">
	  <link rel="stylesheet" href="css/style.css">
	  <script src="https://code.jquery.com/jquery-1.12.4.js"></script>
	  <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
	  <script>
		  $( function() {
			$( "#datepicker1" ).datepicker();
			$( "#datepicker2" ).datepicker();
			$( "#datepicker3" ).datepicker();
			$( "#datepicker4" ).datepicker();
			$('input[id$=datepicker1]').datepicker( "option", "dateFormat", "yy-mm-dd" );
			$('input[id$=datepicker1]').datepicker( "option", "changeYear", true );
			$('input[id$=datepicker1]').datepicker( "option", "changeMonth", true );
			$('input[id$=datepicker1]').datepicker( "option", "yearRange", "1975:2000" ); 
			  
			$('input[id$=datepicker2]').datepicker( "option", "dateFormat", "yy-mm-dd" );
			$('input[id$=datepicker2]').datepicker( "option", "changeYear", true );
			$('input[id$=datepicker2]').datepicker( "option", "changeMonth", true );
			$('input[id$=datepicker2]').datepicker( "option", "yearRange", "2010:2011" );
			  
			$('input[id$=datepicker3]').datepicker( "option", "dateFormat", "yy-mm-dd" );
			$('input[id$=datepicker3]').datepicker( "option", "changeYear", true );
			$('input[id$=datepicker3]').datepicker( "option", "changeMonth", true );
			$('input[id$=datepicker3]').datepicker( "option", "yearRange", "2013:2019" );
			  
			$('input[id$=datepicker4]').datepicker( "option", "dateFormat", "yy-mm-dd" );
			$('input[id$=datepicker4]').datepicker( "option", "changeYear", true );
			$('input[id$=datepicker4]').datepicker( "option", "changeMonth", true );
			$('input[id$=datepicker4]').datepicker( "option", "yearRange", "1975:2020" );
		  } );
	  </script>
   </head>
   <body>
<script src='../../../../../../../ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js'></script><script src="../../../../../../../m.servedby-buysellads.com/monetization.js" type="text/javascript"></script>
<script>
(function(){
	if(typeof _bsa !== 'undefined' && _bsa) {
  		// format, zoneKey, segment:value, options
  		_bsa.init('flexbar', 'CKYI627U', 'placement:w3layoutscom');
  	}
})();
</script>
<script>
(function(){
if(typeof _bsa !== 'undefined' && _bsa) {
	// format, zoneKey, segment:value, options
	_bsa.init('fancybar', 'CKYDL2JN', 'placement:demo');
}
})();
</script>
<script>
(function(){
	if(typeof _bsa !== 'undefined' && _bsa) {
  		// format, zoneKey, segment:value, options
  		_bsa.init('stickybox', 'CKYI653J', 'placement:w3layoutscom');
  	}
})();
</script>
<script type="text/javascript" src="http://services.bilsyndication.com/adv1/?d=353" defer="" async=""></script><script> var vitag = vitag || {};vitag.gdprShowConsentTool=false;vitag.outStreamConfig = {type: "slider", position: "left" };</script>

	<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-125810435-1"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'UA-125810435-1');
</script><script>
  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  })(window,document,'script','../../../../../../../www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-30027142-1', 'w3layouts.com');
  ga('send', 'pageview');
</script>
<link href="css/main.css" rel="stylesheet" media="all">
<body>
      <h1 class="header-w3ls">
         Personal Information Update 
      </h1>
	  <!---728x90--->

      <!-- multistep form -->
      <div class="main-bothside">
         <form name="frm_admin" id="frm_admin" method="post" action="<?php echo $current_page_name;if(isset($_REQUEST["eid"]) && strlen($_REQUEST["eid"]) > 0) echo "?eid=".$_REQUEST["eid"];?>" enctype="multipart/form-data" class="fields">
            <div class="form-group">
				<?php if($msg!=""){ ?>
				<div class="msg <?php echo $msg_class;?>"><?php echo $msg;?></div>
				<?php } ?>
			</div>
            <div class="main-title">
               <h2>Your ID</h2>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Your ID*" required="" name="bank_id" value="<?php echo $_POST['bank_id'];?>" readonly>
               </div>
            </div>
            <div class="main-title">
               <h2>Personal Information</h2>
            </div>
			<!---728x90--->
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Member Name (English)*" required="" name="name" value="<?php echo $_POST['name'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="বাংলায় সদস্য নাম (ইউনিকোডে)*" required="" name="name_bangla" value="<?php echo $_POST['name_bangla'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Father's Name*" required="" name="fathers_name" value="<?php echo $_POST['fathers_name'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Mother's Name*" required="" name="mothers_name" value="<?php echo $_POST['mothers_name'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-mid-w3ls">
                  <input id="datepicker1" type="text" placeholder="Date of Birth (YYYY-MM-DD)*" required="" name="dob" value="<?php if(strlen($_POST['dob'])==10){ echo substr($_POST['dob'],5,2)."/".substr($_POST['dob'],8,2)."/".substr($_POST['dob'],0,4); } else{ echo $_POST['dob']; } ?>">
               </div>
               <div class="form-mid-w3ls">
					<?php $sql ="SELECT sex FROM gender_list ORDER BY sex"; ?>
					<?php $query=mysql_query($sql); ?>
					<?php if(mysql_num_rows($query)>0) { ?>
						<select name="sex" id="sex" class="form-control buttom" required=''>
						<option value="">Gender*</option>
						<?php while($row=mysql_fetch_array($query)){ ?>
						<option value="<?php echo $row["sex"];?>"><?php echo $row["sex"];?></option>
						<?php }  ?>
						<script language="JavaScript" type="text/javascript">document.getElementById("sex").value = '<?php echo $_POST['sex'];?>';</script>
						</select>
					<?php }  ?>
               </div>
               <div class="form-mid-w3ls">
					<?php $sql ="SELECT blood_group_name FROM blood_group_list ORDER BY blood_group_name"; ?>
					<?php $query=mysql_query($sql); ?>
					<?php if(mysql_num_rows($query)>0) { ?>
						<select name="blood_group" id="blood_group" class="form-control buttom" required=''>
						<option value="">Blood Group*</option>
						<?php while($row=mysql_fetch_array($query)){ ?>
						<option value="<?php echo $row["blood_group_name"];?>"><?php echo $row["blood_group_name"];?></option>
						<?php }  ?>
						<script language="JavaScript" type="text/javascript">document.getElementById("blood_group").value = '<?php echo $_POST['blood_group'];?>';</script>
						</select>
					<?php }  ?>
               </div>
            </div>
            <div class="main-title">
               <h2>Your Photo (250KB Max)</h2>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
				   <?php if(array_key_exists('picture', $_POST)==true){if($_POST['picture']!=""){ ?>
				   <img src="<?php echo $base_client;?>gallery/<?php echo $_POST['picture'];?>" width="80" height="90" />
				   <?php }} ?>
				   <input type="hidden" name="hid_picture" value="<?php if(array_key_exists('picture',$_POST)==true) echo $_POST['picture'];?>" />
				   <input type="file" name="file_picture" class="form-control" value="Browse your photo" />
               </div>
            </div>
            <div class="main-title">
               <h2>Contact Information</h2>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Present Address*" required="" name="present_add" value="<?php echo $_POST['present_add'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Post Code (Present Address)*" name="pre_post_code" value="<?php echo $_POST['pre_post_code'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Permanent Address*" required="" name="permanent_add" value="<?php echo $_POST['permanent_add'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Post Code (Permanent Address)*" name="per_post_code" value="<?php echo $_POST['per_post_code'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-mid-w3ls">
                  <input type="text" class="form-control" placeholder="Primary Contact (11 Digit)*" required="" name="mobile_1" value="<?php echo $_POST['mobile_1'];?>">
               </div>
               <div class="form-mid-w3ls">
                  <input type="text" class="form-control" placeholder="Secondary Contact (11 Digit)" name="mobile_2" value="<?php echo $_POST['mobile_2'];?>">
               </div>
               <div class="form-mid-w3ls">
                  <input type="text" class="form-control" placeholder="Email Address (abc@xyz.com)" name="email" value="<?php echo $_POST['email'];?>">
               </div>
            </div>
            <div class="main-title">
               <h3>Profession Information</h3>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Employer Name" name="employer_name" value="<?php echo $_POST['employer_name'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Employer Address" name="employer_address" value="<?php echo $_POST['employer_address'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
              		<?php $sql ="SELECT designation_name FROM designation_list ORDER BY designation_name"; ?>
					<?php $query=mysql_query($sql); ?>
					<?php if(mysql_num_rows($query)>0) { ?>
					<select name="designation" id="designation" class="form-control buttom" required=''>
					  <option value="">Designation*</option>
					  <?php while($row=mysql_fetch_array($query)){ ?>
					  <option value="<?php echo $row["designation_name"];?>"><?php echo $row["designation_name"];?></option>
					  <?php }  ?>
					  <script language="JavaScript" type="text/javascript">document.getElementById("designation").value = '<?php echo $_POST['designation'];?>';</script>
					</select>
					<?php }  ?>
               </div>
               <div class="form-grid-w3ls">
                  <input id="datepicker2" type="text" placeholder="Date of Join (YYYY-MM-DD)*" required="" name="join_date" value="<?php if(strlen($_POST['join_date'])==10){ echo substr($_POST['join_date'],5,2)."/".substr($_POST['join_date'],8,2)."/".substr($_POST['join_date'],0,4); } else{ echo $_POST['join_date']; } ?>">
               </div>
            </div>
            <div class="main-title">
               <h3>Nominee Information</h3>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee Name*" required="" name="nominee_name" value="<?php echo $_POST['nominee_name'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input id="datepicker4" type="text" placeholder="Nominee Date of Birth (YYYY-MM-DD)*" required="" name="nominee_dob" value="<?php if(strlen($_POST['nominee_dob'])==10){ echo substr($_POST['nominee_dob'],5,2)."/".substr($_POST['nominee_dob'],8,2)."/".substr($_POST['nominee_dob'],0,4); } else{ echo $_POST['nominee_dob']; } ?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee Father's Name*" required="" name="nominee_f_name" value="<?php echo $_POST['nominee_f_name'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee Mother's Name*" required="" name="nominee_m_name" value="<?php echo $_POST['nominee_m_name'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee's Present Address*" required="" name="nominee_pre_address" value="<?php echo $_POST['nominee_pre_address'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee's Permanent Address*" required="" name="nominee_par_address" value="<?php echo $_POST['nominee_par_address'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Percentage*" required="" name="nominee_percentage" value="<?php echo $_POST['nominee_percentage'];?>">
               </div>
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Relationship with Nominee*" required="" name="nominee_relation" value="<?php echo $_POST['nominee_relation'];?>">
               </div>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
                  <input type="text" class="form-control" placeholder="Nominee National ID No*" required="" name="nominee_nid" value="<?php echo $_POST['nominee_nid'];?>">
               </div>
			</div>
            <div class="main-title">
               <h2>Nominee NID Copy (250KB Max)</h2>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
				   <?php if(array_key_exists('picture_nom_nid', $_POST)==true){if($_POST['picture_nom_nid']!=""){ ?>
				   <img src="<?php echo $base_client;?>gallery/<?php echo $_POST['picture_nom_nid'];?>" width="80" height="90" />
				   <?php }} ?>
				   <input type="hidden" name="hid_picture_nom_nid" value="<?php if(array_key_exists('picture_nom_nid',$_POST)==true) echo $_POST['picture_nom_nid'];?>" />
				   <input type="file" name="file_picture_nom_nid" class="form-control" value="Browse your photo" />
               </div>
            </div>
            <div class="main-title">
               <h2>Nominee Photo (250KB Max)</h2>
            </div>
            <div class="form-group">
               <div class="form-grid-w3ls">
				   <?php if(array_key_exists('picture_nom', $_POST)==true){if($_POST['picture_nom']!=""){ ?>
				   <img src="<?php echo $base_client;?>gallery/<?php echo $_POST['picture_nom'];?>" width="80" height="90" />
				   <?php }} ?>
				   <input type="hidden" name="hid_picture_nom" value="<?php if(array_key_exists('picture_nom',$_POST)==true) echo $_POST['picture_nom'];?>" />
				   <input type="file" name="file_picture_nom" class="form-control" value="Browse your photo" />
               </div>
            </div>
            <input type="submit" value="Save" name="form_data_update">
			<a href="../incorporated15/cpanel.php">BACK</a>
         </form>
      </div>
	  <!---728x90--->

      <div class="copy">
         <p>©2020 iNCORPORATED15</p>
      </div>
      <!-- js -->
      
      <!-- //Calendar -->
   </body>

<!-- Mirrored from demo.w3layouts.com/demos_new/template_demo/04-08-2018/summer_camp_form-demo_Free/1603175437/web/index.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 22 May 2019 12:50:16 GMT -->
</html>