HEX
Server: Apache
System: Linux 185.122.168.184.host.secureserver.net 5.14.0-570.52.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Oct 15 06:39:08 EDT 2025 x86_64
User: barbeatleanalyti (1024)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: /home/barbeatleanalyti/public_html/barisnew.beatleanalytics.com/site/backup/template/profilenew.php
<link href="http://fontawesome.io/assets/font-awesome/css/font-awesome.css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="theme/black/css/profile.css">

<link href='http://fonts.googleapis.com/css?family=Orbitron' rel='stylesheet' type='text/css'>

<!----wow--->
<script src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.min.js"></script>
<link href='https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.css' rel='stylesheet' type='text/css'>


<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">

<script>
	$(document).ready(function(){
		$("#FromDate").datepicker({format:'dd-mm-yyyy'});
		$("#ToDate").datepicker({format:'dd-mm-yyyy'});
	});

	function validateDate(){

		var D1 = document.getElementById("ToDate");
		var D2 = document.getElementById("FromDate");

		if(D1.value.trim() == ""){
			D1.style.border = "1px solid red";
			return false;
		}

		if(D2.value.trim() == ""){
			D2.style.border = "1px solid red";
			return false;
		}
	}	
	
</script>
<?php
	// Declare new object
$objProfile = object;

	// Assing object 
$objProfile = $objDB->objController;

	// Assign all variable's value
$pg 			= $objProfile->pg;
$acn 			= $objProfile->acn;
$v 			  = $objProfile->v;

$error 			= $objProfile->error;      
$msg 			= $objProfile->msg;

$login		  = $objProfile->login;

$profileimage  = $objProfile->profileimage;
?>
<style>
.head-line {
	margin-top: 2px !important;
	margin-bottom: 2px !important;
}
</style>
<div class="content-wrapper cust_hight">
	<section class="content-header">
		<h1> <i class="fa fa-home"></i> <strong> <span style="font-size:16px !important;" id="org-name"><?php echo $OrgName; ?></span> </strong> </h1>
		<ol class="breadcrumb">
			<li><a href="dashboardma.html"><i class="fa fa-home"></i> Home</a></li>
			<li class="active">Profile</li>
		</ol>
	</section>

  <!---<section class="content-header">
 <h1> 
 <?php if(strtolower($v) == 'list') { ?> Profile details. 
 <?php  }?>
 </h1>
</section>----->

<div class="col-md-12">
	<?php
	// Error or success message display
	$objDB->NotificaitonForResult($msg,$error);

	//echo $uInfo___[0]['userId'];


	$stateid = $uInfo___[0]['db_state'];
	$cityid = $uInfo___[0]['db_city'];
	
	$completepoint = 0;
	
	if(empty($uInfo___[0]['db_userLoginName'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}


	

	if(empty($uInfo___[0]['db_state']) || $uInfo___[0]['db_state'] == 0){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}

	if(empty($uInfo___[0]['db_city']) || $uInfo___[0]['db_city'] == 0){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
	if(empty($uInfo___[0]['db_username'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
	
	if(empty($uInfo___[0]['db_phone'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
	if(empty($uInfo___[0]['db_email'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
	if(empty($uInfo___[0]['db_address'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
	if(empty($uInfo___[0]['db_pincode'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}
	
/*	if(empty($uInfo___[0]['db_aboutme'])){
		$v = 'edit';
	}else{
		$completepoint = $completepoint + 10;
	}*/
	
	?>
</div>
<section class="content">
	<div class="row">
		<div class="col-md-12 col-sm-12 col-xs-12">
			<div class="box box-primary" style="min-height: 978px;"> 

				<!-- /.box-header -->
				<div class="box-body">
					<?php 


					if($pe___ == 'Y') { ?>
						<div class="callout callout-danger text-center">
							<h3>THANK YOU FOR USING <strong>BEATLEANALYTICS.COM PORTAL</strong></h3>
							<h3><em>Please fill and complete your profile first &nbsp;&nbsp;&nbsp; <i class="fa fa-hand-o-down" aria-hidden="true"></i></em></h3>
						</div>
					<?php } ?>
					<?php 
					$ProfileImage = $objProfile->FetchWebProfileImage();

											//$ProfileImage = $objProfile->FetchUserProfilePhoto();
					if($ProfileImage != ""){
						if(!fopen(UPLOAD_WEBPROFILEIMAGE.$ProfileImage,"r")){
							$ProfileImage = _IMAGEPATH_.'/noimage_responsive.png';	
						}else {
							$ProfileImage = UPLOAD_WEBPROFILEIMAGE.$ProfileImage;
							$completepoint = $completepoint + 10;
						}
					}
					else
						$ProfileImage = _IMAGEPATH_.'/noimage_responsive.png';
					?>
					<!----profile-edit-->
					<?php if($v  == 'edit') {?>
						<div class="profie-02" id="edit-pro">

							<div class="header-profile"><h1>Create Your Profile</h1></div>


							<div class="col-md-4 col-sm-12 col-xs-12">
								<div class="profile-left">
									<div class="profile-pic">	
										<div class="profile-pic-top">
											<ul class="img-list1">
												<li style="width:175px; height:175px;">
													<img id="UserWebImage_" src="<?php echo $ProfileImage ;?>" class="img-responsive img-circle" alt="User Image">
												</li>                          
											</ul>

											<button id="#popup_upload_" data-toggle="modal" data-target="#popup_upload"   type="button" class="">Upload Photo</button>
											<p>(Maximum File size 500KB)</p>
										</div>

										<div class="davidar"></div>
										<div class="profile-pic-bottom">
											<div class="profile-completeness">
												<h3>  Profile Completeness : <span style="color:#096"><?php echo $completepoint;?>%</span></h3>
											</div>
											<div class="progress">
												<div class="progress-bar progress-bar-green" role="progressbar" aria-valuenow="<?php echo $completepoint;?>" aria-valuemin="0" aria-valuemax="100" style="width: <?php echo $completepoint;?>%">
													<span class="sr-only">40% Complete (success)</span>
												</div>
											</div>
										</div>
									</div>


								</div>

							</div>

							<!--<input type="hidden" name="ctype" id="ctype" value="<?php echo strtolower($rsUserInfo[0]['UserType'])?>" /> -->
							<div class="col-md-8 col-sm-12 col-xs-12 filled-section-right">
								<form name="frmSettings" id="frmSettings" method="post" action="manage.php?pg=profilenew&acn=setSettingData" enctype="multipart/form-data" > 
									<input type="hidden" name="acn" id="acn" value="setSettingData" />
									<input type="hidden" name="pg" id="pg" value="profilenew" />
									<div class="col-md-6 col-sm-12 col-xs-12">
										<div class="profile-right">
											<div class="box-body">



												<br>



												<h4>Choose Id <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-id-badge"></i></span>
													<input name="username" id="username" type="text" <?php if(!empty($uInfo___[0]['db_userLoginName'])) echo 'readonly="readonly"'; ?> class="form-control" placeholder="Choose Id" value="<?php echo $uInfo___[0]['db_userLoginName'];?>">
												</div>
												<br>
												<h4>Full Name <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-user"></i></span>
													<input type="email" class="form-control" placeholder="Full Name" name="name" id="name" value="<?php echo $uInfo___[0]['db_username'];?>">
												</div>
												<br>
												<h4>Email Id <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-envelope" aria-hidden="true"></i></span>
													<input type="email" class="form-control" placeholder="Email Id" name="email" id="email"  value="<?php echo $uInfo___[0]['db_email'];?>">
												</div>
												<br>
												<h4>Phone No <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-mobile"></i></span>
													<input type="email" class="form-control" placeholder="Phone No" name="contact_number" id="contact_number" value="<?php echo $uInfo___[0]['db_phone'];?>">
												</div>
												<br>
												<h4>Address <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-address-card"></i></span>
													<input type="email" class="form-control" placeholder="Address" name="address" id="address" value="<?php echo $uInfo___[0]['db_address'];?>">
												</div>
												<br>
											</div>
										</div>


									</div>

									<div class="col-md-6 col-sm-12 col-xs-12">
										<div class="profile-right">
											<div class="box-body">
												<br />





												<h4>PIN Code <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-file-archive-o"></i></span>
													<input type="email" class="form-control" placeholder="PIN Code" id="pincode" maxlength="6"  name="pincode" value="<?php echo $uInfo___[0]['db_pincode'];?>">
												</div>
												<br>

												<h4>State <span style="color:red">*</span></h4>

												<div class="input-group">
													<span class="input-group-addon"><i class="fa fa-flag"></i></span>
													<!--<select class="form-control" id="status" name="status"> -->
														<select onchange="javascript: fetchCityData(this.value)" class="form-control" name="state" id="state">
															<?php 
															$SQL = "SELECT * FROM states where country_id = 101 order by name ASC ";
															$rsStates = $objDB->sql_query($SQL);
															for($s = 0; $s<count($rsStates); $s++) {

																if(empty($stateid)){
																	$stateid = $rsStates[0]['id'];
																}
																$selState = '';
																if($stateid == $rsStates[$s]['id']){
																	$selState = 'selected="selected"';
																}

																?>
																<option <?php echo $selState;?> value="<?php echo $rsStates[$s]['id']?>"><?php echo $rsStates[$s]['name']?></option>
															<?php } ?>
														</select> 
													</div>
													<br>
													<h4>City <span style="color:red">*</span></h4>

													<div class="input-group">
														<span class="input-group-addon"><i class="fa fa-building"></i></span>
														<span id="city-data">
															<select class="form-control" name="city" id="city">

																<?php $SQL = "SELECT * FROM cities where state_id = ".$stateid." order by name ASC ";
																$rsCity = $objDB->sql_query($SQL);
																for($s = 0; $s<count($rsCity); $s++) {

																	$selState = '';
																	if($cityid == $rsCity[$s]['id']){
																		$selState = 'selected="selected"';
																	}

																	?>
																	<option <?php echo $selState; ?> value="<?php echo $rsCity[$s]['id']?>"><?php echo $rsCity[$s]['name']?></option>
																<?php } ?>
															</select> 
														</span>
													</div>
													<br>
													<h4>About Me</h4>

													<div class="input-group">
														<span class="input-group-addon"><i class="fa fa-commenting-o" aria-hidden="true"></i></span>
														<textarea class="form-control" rows="3" name="aboutme" id="aboutme" placeholder="Write something about you here.."><?php echo $uInfo___[0]['db_aboutme'];?></textarea>
													</div>
													<br>

													<script>
														function fetchCityData(sid){
															var xhttp = new XMLHttpRequest();
															xhttp.onreadystatechange = function() {
																if (this.readyState == 4 && this.status == 200) {
																	document.getElementById("city-data").innerHTML = this.responseText;
																}
															};
															xhttp.open("GET", "runajax.php?acn=fetchCityData&sid="+sid, true);
															xhttp.send(); 
														}


														function validateAddress(TCode){
															if(/[^a-zA-Z0-9\/]/.test( TCode )) {
																document.getElementById('username').value = TCode.slice(0, -1)
																return false;
															}
															return true;
														}

														function validateFrom(){

															var name = document.getElementById('name');
															var contact_number = document.getElementById('contact_number');
															var email = document.getElementById('email');
                                            //var user_name_hdn = document.getElementById('user_name_hdn');
                                            var username = document.getElementById('username');

                                            var address = document.getElementById('address');
                                            var pincode = document.getElementById('pincode');
                                            
                                            
                                            var error = 0;

											//if(user_name_hdn.value.trim() == ""){
												if(username.value.trim() == ""){
													username.style.border = "1px solid red";
													error = 1;
												}else{
													username.style.border = "1px solid #ccc";
												}
												
											//}
											
											
											
											if(name.value.trim() == ""){
												name.style.border = "1px solid red";
												error = 1;
											}else{
												name.style.border = "1px solid #ccc";
											}
											if(contact_number.value.trim() == ""){
												contact_number.style.border = "1px solid red";
												error = 1;
											}else{
												contact_number.border = "1px solid #ccc";
											}
											if(contact_number.value.length != 10){
												contact_number.style.border = "1px solid red";
												error = 1;
											}else{
												contact_number.style.border = "1px solid #ccc";
											}

											if(ValidateEmail(email) == false){
												email.style.border = "1px solid red";
												error = 1;
											}else{
												email.style.border = "1px solid #ccc";
											}
											
											if(address.value.trim() == ""){
												address.style.border = "1px solid red";
												error = 1;
											}else{
												address.style.border = "1px solid #ccc";
											}
											
											if(pincode.value.trim() == "" || pincode.value.trim() == 0){
												pincode.style.border = "1px solid red";
												error = 1;
											}else{
												if(pincode.value.trim().length != 6){
													pincode.style.border = "1px solid red";
													error = 1;
												}else{
													pincode.style.border = "1px solid #ccc";
												}
											}

											if(error == 1)
												return false;
											
											document.getElementById('frmSettings').submit();
											
										}




										function isNumber(evt) {
											evt = (evt) ? evt : window.event;
											var charCode = (evt.which) ? evt.which : evt.keyCode;
											if (charCode > 31 && (charCode < 48 || charCode > 57)) {
												return false;
											}
											return true;
										}

										function ValidateEmail(mail) 
										{
											if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(mail.value.trim()))
											{
												return true;
											}
                                        //alert("You have entered an invalid email address!")
                                        return false;
                                    }

                                </script>

                            </div>

                        </div>


                    </div>

                </form>                
                

                <div class=" col-md-12 col-sm-12 col-xs-12 box-footerbutton-save-edit-chang-pass">

                	<button type="submit" onclick="javascript: return validateFrom();"  id="save" class="btn btn-info" style="font-size: 20px; padding: 11px 37px;">Save</button>
                	<button type="button" class="btn btn-warning" data-toggle="modal" data-target="#modal-warning" style="    font-size: 20px; padding: 11px 37px;">
                		Change Password
                	</button>

                	<div class="modal modal-warning fade in" id="modal-warning" style="display: none; padding-right: 17px;">
                		<div class="modal-dialog">
                			<div class="modal-content">
                				<div class="modal-header" style="border-radius: 8px 8px 0px 0px;">
                					<button type="button" class="close" data-dismiss="modal" aria-label="Close">
                						<span aria-hidden="true">×</span></button>
                						<h4 class="modal-title">Change Password</h4>
                					</div>
                					<form name="frmSettings" id="frmSettings" method="post" action="manage.php?pg=profileemp&acn=setPasswordData" enctype="multipart/form-data" > 
                						<input type="hidden" name="ctype" id="ctype" value="<?php echo strtolower($rsUserInfo[0]['UserType'])?>" />
                						<div class="modal-body" style="padding:37px !IMPORTANT;">
                							<div class="chang-pass">
                								<div class="form-group">
                									<label for="amount" class="col-sm-5 control-label">Old password</label>
                									<div class="col-sm-7">
                										<input type="password" class="form-control" id="oldpass" name="oldpass">
                									</div>
                								</div>

                								<div class="form-group">
                									<label for="amount" class="col-sm-5 control-label">New password</label>
                									<div class="col-sm-7">
                										<input type="password" class="form-control" id="newpass" name="newpass">
                									</div>
                								</div>

                								<div class="form-group">
                									<label for="amount" class="col-sm-5 control-label">Confirm password</label>
                									<div class="col-sm-7">
                										<input type="password" class="form-control" id="cnewpass" name="cnewpass">
                									</div>
                								</div>





                							</div>
                						</div>
                						<div class="modal-footer" style="border-radius:0px 0px 8px 8px;">
                							<button type="button" class="btn btn-outline pull-left" data-dismiss="modal">Close</button>
                							<!--<button type="button" class="btn btn-outline">Save changes</button> -->
                							<button type="submit" onclick="javascript: return validatePassword();" class="btn btn-outline">Save changes</button>
                						</div>

                						<script>
                							function validatePassword(){

                								var oldpass = document.getElementById('oldpass');
                								var newpass = document.getElementById('newpass');
                								var cnewpass = document.getElementById('cnewpass');
                								var error = 0;



                								if(oldpass.value.trim() == ""){
                									oldpass.style.border = "1px solid red";
                									error = 1;
                								}else{
                									oldpass.style.border = "1px solid #ccc";
                								}


                								if(newpass.value.trim() == ""){
                									newpass.style.border = "1px solid red";
                									error = 1;
                								}else{

                									if(newpass.value.length < 6 || newpass.value.length > 20){
                										newpass.style.border = "1px solid red";
                                                	//alert("new pas error");
                                                	error = 1;
                                                }else{
                                                	newpass.style.border = "1px solid #ccc";
                                                }

                                            }


                                            


                                            if(cnewpass.value.trim() == ""){
                                            	cnewpass.style.border = "1px solid red";
                                            	error = 1;
                                            }else{

                                            	if(cnewpass.value.length < 6 || cnewpass.value.length > 20){
                                            		cnewpass.style.border = "1px solid red";
                                                	//alert("cpass eror");
                                                	error = 1;
                                                }else{
                                                	cnewpass.style.border = "1px solid #ccc";
                                                }
                                            }

											//alert(error);
											if(error == 1)
												return false;
											
											if(newpass.value.trim() != cnewpass.value.trim()){
												alert("Confirm password not matched.");
												cnewpass.style.border = "1px solid red";
												error = 1;
											}else{
                                               // cnewpass.style.border = "1px solid #ccc";
                                           }

                                           if(error == 1)
                                           	return false;



                                       }
                                   </script>


                               </div>
                               <!-- /.modal-content -->
                           </div>
                           <!-- /.modal-dialog -->
                       </div>





                   </div>

               </div>

               <style>
               .profie-02 .box-footerbutton-save-edit-chang-pass {text-align: center; margin-bottom:20px;}
               .profie-02 .davidar {width: 100%; height: 2px;  background: #9a9494;}
               .profie-02 .profile-left {text-align: center;}
               .profie-02 .profile-pic {text-align: center; margin: 0 auto;}
               .profie-02 .profile-pic img {margin: 0 auto;}
               .profie-02 .progress {  width: 80%;margin: 18px auto;}
               .profie-02 .profile-completeness h3 {
               	text-align: left;
               	width: 80%;
               	margin: 0 auto;
               }
               .profie-02 .profile-pic {
               	border: 1px solid #ddd;
               	padding: 6px;
               }
               .profie-02 .profile-pic img#UserWebImage_ {
               	border-radius: 100%;
               	background: whitesmoke;
               	padding: 14px;
               }
               .profie-02 .profile-pic-top , .profile-pic-bottom {
               	margin-top: 49px; margin-bottom: 52px;
               }
               .profie-02 .profile-pic-top button {
               	margin-top: 15px;
               	background: #1caf9a;
               	border: none;
               	border-radius: 3px;
               	padding: 5px 18px;
               	font-size: 16px;
               	color: #FFF;
               }
               .profie-02 .profile-pic-top p {
               	margin-top: 15px;
               	font-size: 20px;
               }

               .profie-02 .profile-right {
               	width: 90%;
               	margin: 0 auto;
               }
               .profie-02 .profile-right input {
               	padding: 9px 10px;
               	font-size: 17px;
               	background: #f4efef;
               }
               .profie-02 .profile-right .input-group i {
               	font-size: 19px;
               	margin: 0 6px;
               }
               .profie-02 .profile-right h4 {
               	margin: 0px;
               }


               .header-profile {
               	background: #f4efef;
               	padding: 25px 42px;
               	margin-top: 39px;
               	margin-bottom: 13px;
               }
               .header-profile h1 {
               	padding: 0px;
               	margin: 0px;
               }
               .profie-02.filled-section-right {
               	border: 1px solid #dddddd;
               }

               .profie-02 i.fa.fa-envelope {
               	margin: 0 4px;
               }
               .profie-02 i.fa.fa-mobile {
               	padding: 0 1px;
               	font-size: 30px;
               }
               .profie-02 i.fa.fa-commenting-o {
               	font-size: 25px !IMPORTANT;
               	padding: 0px !IMPORTANT;
               	margin: 0 2px !IMPORTANT;
               }
               .profie-02 i.fa.fa-address-card {
               	font-size: 20px;
               	padding: 0px;
               	margin: 0px 3px;
               }

               .profie-02 .col-md-12.col-sm-12.col-xs-12.box-footer {
               	border: none;
               	text-align: center;
               }
               .filled-section-right {
               	border: 1px solid #dddddd;
               }
               .col-md-12.col-sm-12.col-xs-12.box-footer button {
               	font-size: 26px;
               	padding: 12px 48px;
               }
               .input-group select {
               	padding: 11px 0 !IMPORTANT;
               	background: #f4efef !IMPORTANT;
               	color: #999999 !IMPORTANT;
               }
               textarea.form-control {
               	padding: 3px 7px;
               	background: #f4efef;
               	font-size: 14px;
               }
               .diyaidar-profile {
               	margin-top: 225px;
               	width: 100%;
               	float: left;
               	height: 5px;
               	background: #222d32;
               }
           </style>
       </div>
   <?php } else { ?>
   	<div class="new-profile" id="complit-pro">

   		<!----------------------owner----start--------------------------------------------------------------------------------start------------------------------------------------------------------------------start------------------------------------------------------------------------------start---------------------------------------------------------------------------->



   		<!--------------------------------------19-9-2018--------------------------------------------------------->
   		<?php if($_SESSION['UserInfo']['UType'] != 'End_user') { ?>

   			<div class="profile_new_19-9-2018">
   				<div class="employ_title">
   					<div class="employ_name">
   						<h1><?php echo $uInfo___[0]['db_userLoginName']?></span></h1>
   					</div>
   				</div>


   				<div class="navigaton_filed">
   					<div class="sub_nevi">
   						<span><?php

   						if($_SESSION['UserInfo']['UType'] == 'owner'){
   							echo $objProfile->FetchOrganizationName($uInfo___[0]['OrgID']);
   						}elseif($_SESSION['UserInfo']['UType'] == 'manager'){
   							echo $objProfile->FetchBranchName($uInfo___[0]['BranchID']);
   						}else{
   							echo $objProfile->FetchIndustryName($uInfo___[0]['IndustryID']);
   						}
   						?></span>
   					</div>

   					<div class="profile-pic-bottom complit_pr pull-right">
   						<div class="profile-completeness">
   							<h3>  Profile Completeness : <span style="color:#06964f;"><?php echo $completepoint;?>%</span></h3>
   						</div>
   						<div class="progress">
   							<div class="progress-bar progress-bar-green" role="progressbar" aria-valuenow="<?php echo $completepoint;?>" aria-valuemin="0" aria-valuemax="100" style="width: <?php echo $completepoint;?>%">
   								<span class="sr-only">40% Complete (success)</span>
   							</div>
   						</div>
   					</div>

   				</div>

   				<div class="col-md-2 fram_br profile_card">
   					<div class="profile_card">
   						<div class="profile_pic">


   							<ul class="img-list1">


   								<li class="customer-profile" style="width:112px; height:112px;">
   									<img id="UserWebImage_" src="<?php echo $ProfileImage; ?>" class="img-responsive " alt="User Image">
   									<a href="#popup_upload_" data-toggle="modal" data-target="#popup_upload">
   										<span class="text-content1 cust-chang-img" style="    width: 100%;
   										border-radius: 0px;
   										height: 248px;
   										background: #242f348f !IMPORTANT;
   										margin-top: 10px;"><span><strong>Change Image</strong></span></span>

   									</a>

   								</li> 


   							</ul>

   						</div>
   						<p class="full_name"><?php echo $uInfo___[0]['db_username']?></p>
   						<p class="position_dashbord">DASHBORD :<span> <?php echo $uInfo___[0]['db_usertype']?> </span></p>
   						<!-- <p class="last_login_time">LAST LOGIN :<span> TODAY 10PM </span></p> -->

   						<div class="velidity_date">
   							<p class="title_per">Registration Date:</p>
   							<span class="title_per_info"><?php echo date("d-M-Y",strtotime($uInfo___[0]['created_date']));?></span>
   							<?php $ownerdata = $objProfile->FetchOwnerData($uInfo___[0]['OrgID']);?>
   							<hr style=" padding: 0px; margin: 3px;">
   							<p class="title_per">Expiry Date:</p>
   							<span class="title_per_info expiry_date"><?php echo date("d-M-Y",strtotime($ownerdata [0]['db_valid']));?></span>
   						</div>
   					</div>
   				</div>
   				<div class="col-md-10">
   					<div class="col-md-3">
   						<div class="fram_br per_info persnal_info">
   							<h3><i class="fas fa-user"></i> Persanal Info</h3>

   							<p class="title_per">Phone No</p>
   							<span class="title_per_info"><?php echo $uInfo___[0]['db_phone']?></span></span>

   							<p class="title_per">Email Id</p>
   							<span class="title_per_info"><?php echo $uInfo___[0]['db_email']?></span></span>		

   							<p class="title_per">Address</p>
   							<span class="title_per_info"><?php echo $uInfo___[0]['db_address']?></span>

   							<p class="title_per">PIN Code</p>
   							<span class="title_per_info"><?php echo $uInfo___[0]['db_pincode']?></span>

   							<?php 
   							$st = '';
   							if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
   								$SQL = "SELECT * FROM states where id = ".$uInfo___[0]['db_state']." order by name ASC ";
   								$rsStates_ = $objDB->sql_query($SQL);
   								$st = $rsStates_[0]['name'];
   							}


   							$ct = '';
   							if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
   								$SQL = "SELECT * FROM cities where id = ".$uInfo___[0]['db_city']." order by name ASC ";
   								$rsCity_ = $objDB->sql_query($SQL);
   								$ct = $rsCity_[0]['name'];
   							}
   							?>

   							<p class="title_per">State</p>
   							<span class="title_per_info"><?php echo $st?></span>

   							<p class="title_per">City</p>
   							<span class="title_per_info"><?php echo $ct?></span>

   							<p class="title_per">About me</p>
   							<span class="title_per_info"><?php echo $uInfo___[0]['db_aboutme']?></span>
   						</div>

   						<div class="view_button_redeem">
   							<button class="manage_btl_point" data-toggle="modal" data-target="#modal-default-owner" title="Redeem" style="background:#222d32">Redeem</button>
   							<button class="manage_btl_point"  data-toggle="modal" data-target="#modal-default-owner12" title="Purchase" style="background:#222d32">Purchase</button>



   						</div>
   					</div>

   					<div class="col-md-9">
   						<div class="col-md-12 fram_br point_count">
   							<div class="title_view">
   								<h2>Stauts</h2>
   								<div class="count_number">
   									<div class="cun_num">
   										<h3>0<!---<?php echo fetchTotalPointsClient();?>---></h3>
   										<p>Beatle Points</p>
   										<span class="view_all_btn">view all</span>
   									</div>
   								</div>
   								<div class="count_number">
   									<div class="cun_num">
   										<h3>0<!--<?php echo fetchRemainPointClient('email');?>---></h3>
   										<p>Emails</p>
   										<span class="view_all_btn">view all</span>
   									</div>
   								</div>
   								<div class="count_number">
   									<div class="cun_num">
   										<h3>0</h3>
   										<p>Offers</p>
   										<span class="view_all_btn">view all</span>
   									</div>
   								</div>
   								<div class="count_number">
   									<div class="cun_num">
   										<h3>0</h3>
   										<p>SMS</p>
   										<span class="view_all_btn">view all</span>
   									</div>
   								</div>
   								<div class="count_number">
   									<div class="cun_num">
   										<h3>0</h3>
   										<p>Customers</p>
   										<span class="view_all_btn">view all</span>
   									</div>
   								</div>
   							</div>
   						</div>
   						<div class="col-md-12 fram_br- staff-" style="padding:0px !IMPORTANT;">
   							<div class="staff">
   								<div class="col-md-4 manager" style="padding-left:0px;">
   									<div class="all_staff">
   										<img src="theme/black/images/manager_icon.png">
   										<h3>Manager</h3>
   										<p><?php
	   										$branchDetails = $objProfile->getAllBranchByOrg($uInfo___[0]['OrgID']);
	   										echo(count($branchDetails));
   										?></p>
   									</div>
   								</div>
   								<div class="col-md-4 line_manager">
   									<div class="all_staff">
   										<img src="theme/black/images/line_manager_icon.png">
   										<h3>Line Manager</h3>
   										<p><?php
   											$indCount = 0;
   											for($i = 0; $i < count($branchDetails); $i++){
   												//echo($branchDetails[$i]['branchId']);
   												
   												$indDetails = $objProfile->getAllIndByBranch($branchDetails[$i]['branchId']);
   												//echo(count($indDetails));
   												$indCount = $indCount + count($indDetails);
												

   											}
   											echo($indCount);
   										?></p>
   									</div>
   								</div>
   								<div class="col-md-4 attendant" style="padding-right:0px !IMPORTANT;" title="feature coming soon">
   									<div class="all_staff">
   										<img src="theme/black/images/attentent_icon.png">
   										<h3>Attendant</h3>
   										<p>00</p>
   									</div>
   								</div>				
   							</div>
   						</div>
   					</div>
   					<div class="col-md-12 fram_br action_right">
   						<div class="action_view">
   							<div class="text_act">Action</div>
   							<div class="action_btn">
   								<a href="profilenew.html?v=edit"><i class="far fa-edit"></i> Edit Profile</a> 
   								<a href=""> <i class="fas fa-users"></i> View all Employ</a>
   								<a href=""> <i class="fa fa-building-o" aria-hidden="true"></i> Edit organation Pic</a> </div>
   							</div>	

   						</div>
   					</div>

   				</div>
   			<?php } ?>
   			<!----------------------------------//-19-9-2018--------------------------------------------------------------------->



   			<!--------10-7-2018--new_last---------->

   			<?php //if($_SESSION['UserInfo']['UType'] == 'manager') { ?> 
   				<div class="owner_profile"   style="display:none;">

   					<div class="heder_pr">
   						<!--org_name_&_about_me-->	  
   						<div class="col-md-3">
   							<div class="o-profile-heder">
   								<h3 data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;"><?php echo $orgname = $objProfile->FetchOrganizationName($uInfo___[0]['OrgID']);?></h3>
   								<div class="about">
   									<h4 style="margin-left: 50px;"> <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_aboutme']?></span></h4>
   								</div>

   							</div>
   						</div>
   						<!--//org_name_&_about_me-->

   						<!--clock--->
   						<div class="col-md-6 countr">
   							<p id="demo"></p>
   						</div>
   						<!--//clock-->

   						<!--velidity-->
   						<div class="col-md-3"> 
   							<div class="veliditi_date">
   								<h4 class="badge bg-green">Registration Date:<span>(<?php echo date("d-M-Y",strtotime($uInfo___[0]['created_date']));?>)</span></h4>
   								<?php $ownerdata = $objProfile->FetchOwnerData($uInfo___[0]['OrgID']);?>
   								<h4 class="badge bg-red" data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;">Expiry Date: <span>(<?php echo date("d-M-Y",strtotime($ownerdata [0]['db_valid']));?>)</span></h4> 
   							</div>
   						</div>
   						<!--//velidity-->

   					</div>

   					<!-------date-counter----->	
   					<script>

   						var date = "<?php echo date("d-M-Y",strtotime($ownerdata [0]['db_valid']));?>";
// Set the date we're counting down to
var countDownDate = new Date(date).getTime();

	// Update the count down every 1 second
	var x = setInterval(function() {

    // Get todays date and time
    var now = new Date().getTime();
    
    // Find the distance between now an the count down date
    var distance = countDownDate - now;
    
    // Time calculations for days, hours, minutes and seconds
    var days = Math.floor(distance / (1000 * 60 * 60 * 24));
    var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
    var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
    var seconds = Math.floor((distance % (1000 * 60)) / 1000);
    
    // Output the result in an element with id="demo"
    document.getElementById("demo").innerHTML = days + "d " + hours + "h "
    + minutes + "m " + seconds + "s ";
    
    // If the count down is over, write some text 
    if (distance < 0) {
    	clearInterval(x);
    	document.getElementById("demo").innerHTML = "EXPIRED";
    }
}, 1000);
</script>	



<div class="col-md-12 member_profile wow bounceInRight animated" style="visibility: visible; animation-name: bounceInRight;">

	<!------ Include the above in your HEAD tag ---------->

	<div class="container-">
		<div class="row">

			<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 toppad" >


				<div class="panel panel-info">
					<div class="panel-heading">
						<h3 class="panel-title pull-left">Profile Info</h3>
						<h3 class="panel-title pull-right"><i class="fa fa-circle text-success" style="font-size: 11px !IMPORTANT;"></i> Last Login : <span>10:15 AM</span></h3>
					</div>
					<div class="panel-body">
						<div class="row">
							<div class="col-md-3 col-lg-3 ch_pr" align="center"> 
								<!---<img class=" col-lg-4 profile-user-img img-responsive img-circle" src="theme/black/images/blank_man.png" alt="User profile picture" style="padding:5px;">-->


								<div class="profile-img">


									<ul class="img-list1">


										<li class="customer-profile" style="width:112px; height:112px;">
											<img id="UserWebImage_" src="<?php echo $ProfileImage; ?>" class="img-responsive " alt="User Image">
											<a href="#popup_upload_" data-toggle="modal" data-target="#popup_upload">
												<span class="text-content1 cust-chang-img" style="    width: 112px;
												border-radius:300px;
												height: 112px; background: #242f348f !IMPORTANT;"><span><strong>Change Image</strong></span></span>

											</a>

										</li> 


									</ul>

								</div>



							</div>


							<div class=" col-md-9 col-lg-9 "> 

								<table class="table table-user-information">
									<tbody>
										<tr>
											<td>Profile id :</td>
											<td> <span><?php echo $uInfo___[0]['db_userLoginName']?></span></td>
										</tr>
										<tr>
											<td>Full Name :</td>
											<td>  <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_username']?></span></td>
										</tr>
										<tr>
											<td>Email Id :</td>
											<td> <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_email']?></span></td>
										</tr>

										<tr>
											<td> Phone no : </td>
											<td>  <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_phone']?></span></td>
										</tr>


										<tr>
											<td>Address : </td>
											<td> <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_address']?></span></td>
										</tr>


										<tr>
											<td>PIN Code : </td>
											<td><span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_pincode']?></span><span class="edit"></span></td>
										</tr>
										<?php 
										$st = '';
										if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
											$SQL = "SELECT * FROM states where id = ".$uInfo___[0]['db_state']." order by name ASC ";
											$rsStates_ = $objDB->sql_query($SQL);
											$st = $rsStates_[0]['name'];
										}


										$ct = '';
										if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
											$SQL = "SELECT * FROM cities where id = ".$uInfo___[0]['db_city']." order by name ASC ";
											$rsCity_ = $objDB->sql_query($SQL);
											$ct = $rsCity_[0]['name'];
										}
										?>


										<tr>
											<td>State :  </td>
											<td><span  id="lblName" class="editable" ><?php echo $st?></span></td>
										</tr>

										<tr>
											<td>City : </td>
											<td> <span  id="lblName" class="editable" ><?php echo $ct?></span></td>
										</tr>












									</tbody>
								</table>

								<a href="profilenew.html?v=edit" class="btn btn-primary black_btn">Edit</a>

							</div>
						</div>
					</div>


				</div>
			</div>

			<div class="col-md-6 pro_other_scr">


				<div class="profile-pic-bottom complit_pr">
					<div class="profile-completeness">
						<h3>  Profile Completeness : <span style="color:#06964f;"><?php echo $completepoint;?>%</span></h3>
					</div>
					<div class="progress">
						<div class="progress-bar progress-bar-green" role="progressbar" aria-valuenow="<?php echo $completepoint;?>" aria-valuemin="0" aria-valuemax="100" style="width: <?php echo $completepoint;?>%">
							<span class="sr-only">40% Complete (success)</span>
						</div>
					</div>
				</div>
				<div class="row" style="margin-top: 35px;">



					<div class="col-lg-6 col-xs-6 img-responsive top_img">
						<!-- small box -->
						<div class="small-box bg-aqua">
							<div class="inner">
								<h3><?php echo fetchTotalPointsClient();?></h3>

								<p>Beatle Point</p>
							</div>
							<div class="icon">

								<img data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;" src="theme/black/images/posints-multi.png" >
							</div>
							<a href="#" class="small-box-footer">More info <i class="fa fa-arrow-circle-right"></i></a>
						</div>
					</div>
					<!-- ./col -->
					<div class="col-lg-6 col-xs-6 img-responsive">
						<!-- small box -->
						<div class="small-box bg-green">
							<div class="inner">
								<h3>0</h3>

								<p>Beatle SMS</p>
							</div>
							<div class="icon">
								<img data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;" src="theme/black/images/pr_sms.png" >
							</div>
							<a href="#" class="small-box-footer">More info <i class="fa fa-arrow-circle-right"></i></a>
						</div>
					</div>
					<!-- ./col -->
					<div class="col-lg-6 col-xs-6 img-responsive">
						<!-- small box -->
						<div class="small-box bg-yellow">
							<div class="inner">
								<h3><?php echo fetchRemainPointClient('email');?></h3>

								<p>Beatle Email</p>
							</div>
							<div class="icon">
								<img data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;" src="theme/black/images/pr_email.png" >
							</div>
							<a href="emailer.html?v=report" class="small-box-footer">More info <i class="fa fa-arrow-circle-right"></i></a>
						</div>
					</div>

					<div class="col-lg-6 col-xs-6 img-responsive">
						<!-- small box -->
						<div class="small-box bg-red">
							<div class="inner">
								<h3>950</h3>

								<p>Total Customer</p>
							</div>
							<div class="icon">

								<img  data-wow-delay="300ms" data-wow-iteration="infinite" data-wow-duration="2s" style="visibility: visible; animation-duration: 2s; animation-delay: 300ms; animation-iteration-count: infinite; animation-name: pulse;"src="theme/black/images/pr_customar.png" >
							</div>
							<a href="#" class="small-box-footer">
								More info <i class="fa fa-arrow-circle-right"></i>
							</a>
						</div>
					</div>
					<!-- ./col -->

					<div class="col-md-3"></div>

					<div class="col-md-3"><button type="button" href="#" data-toggle="modal" data-target="#modal-default-owner" title="Redeem" class="btn btn-block btn-success black_btn">Redeem</button> </div> 

					<div class="col-md-3"><button type="button" href="#" data-toggle="modal" data-target="#modal-default-owner12" title="Purchase" class="btn btn-block btn-success black_btn">Purchase</button></div> 
					<div class="col-md-3"></div>	   
				</div>




			</div>


		</div>
	</div>



</div>


<div class="history-beatle">
	<div class="col-md-3 wow bounceInRight animated" style="visibility: visible; animation-name:bounceInUp;">
		<div class="box box-warning box-solid">
			<div class="box-header with-border pr_hed">
				<h3 class="box-title">Redeem History</h3>

				<div class="box-tools pull-right">
					<button type="button" class="btn btn-box-tool waves-effect waves-circle waves-light" data-widget="collapse"><i class="fa fa-minus"></i>
					</button>
				</div>
				<!-- /.box-tools -->
			</div>
			<!-- /.box-header -->
			<div class="box-body per-info">


				<marquee scrollamount="2" id="scroll_news1" direction="up"><div class="mrq" onmouseover="document.getElementById('scroll_news1').stop();" onmouseout="document.getElementById('scroll_news1').start();" style="height:218px;">


					<div class="box-body">
						<div class="table-responsive">
							<table class="table no-margin">
								<thead style="background:none !important;">
									<tr>
										<th>Date</th>

										<th>Point/ Rs.</th>
									</tr>
								</thead>
								<tbody>
									<?php
									$rsRedeemData = fetchAllRedeemData();
									if(count($rsRedeemData) > 0) {
										for($rp=0; $rp<count($rsRedeemData); $rp++) {
											?>
											<tr>
												<td><?php echo date("d/m/Y",strtotime($rsRedeemData[$rp]['created_date']));?></td>
												<td><span class=""> <span>Point</span> - <?php echo $rsRedeemData[$rp]['point'];?> </span></td>
											</tr>
										<?php } 

									}else{ ?>
										<tr>
											<td colspan="2"> No any data found </td>
										</tr>
									<?php } ?>  



								</tbody>
							</table>
						</div>

					</div>

				</div></marquee>
			</div>
			<!-- /.box-body -->
		</div>
		<!-- /.box -->
	</div>

	<div class="col-md-3 wow bounceInRight animated" data-wow-offset="300" style="visibility: visible; animation-name:bounceInUp;">
		<div class="box box-warning box-solid">
			<div class="box-header with-border pr_hed">
				<h3 class="box-title">Purchase History</h3>

				<div class="box-tools pull-right">
					<button type="button" class="btn btn-box-tool waves-effect waves-circle waves-light" data-widget="collapse"><i class="fa fa-minus"></i>
					</button>
				</div>
				<!-- /.box-tools -->
			</div>



			<!-- /.box-header -->
			<div class="box-body per-info">
				<marquee scrollamount="2" id="scroll_news" direction="up"><div class="mrq purch" onmouseover="document.getElementById('scroll_news').stop();" onmouseout="document.getElementById('scroll_news').start();" style="height:215px;">

					<div class="box-body">
						<div class="table-responsive">
							<table class="table no-margin">
								<thead style="background:none !important;">
									<tr>
										<th>Date</th>
										<th>Status</th>
										<th>Point/ Rs.</th>
									</tr>
								</thead>
								<tbody>
									<?php
									$rsRedeemData = fetchAllPurchaseHistoryData();
									if(count($rsRedeemData) > 0) {
										for($rp=0; $rp<count($rsRedeemData); $rp++) {
											?>
											<tr>
												<td><?php echo date("d/m/Y",strtotime($rsRedeemData[$rp]['created_date']));?></td>
												<td><span class=""><?php echo $rsRedeemData[$rp]['status'];?> </span></td>
												<td><span class=""> <span>Rs</span> - <?php echo $rsRedeemData[$rp]['totalprice'];?>/- </span></td>
											</tr>
										<?php } 

									}else{ ?>
										<tr>
											<td colspan="2"> No any data found </td>
										</tr>
									<?php } ?>  



								</tbody>
							</table>
						</div>

					</div>

				</div></marquee>
			</div>
			<!-- /.box-body -->
		</div>
		<!-- /.box -->
	</div>

	<?php
	$SQL = "SELECT * FROM beatle_offers  WHERE orgid = ".$_SESSION['OtherInfo']['OrgID']." ORDER BY startdate DESC";
	$rsOfferData = $objDB->sql_query($SQL);
	?>

	<div class="col-md-6 wow bounceInRight animated" data-wow-offset="300" style="visibility: visible; animation-name:bounceInUp;">
		<div class="box box-warning box-solid">
			<div class="box-header with-border pr_hed">
				<h3 class="box-title">Latest offer</h3>

				<div class="box-tools pull-right">
					<button type="button" class="btn btn-box-tool waves-effect waves-circle waves-light" data-widget="collapse"><i class="fa fa-minus"></i>
					</button>
				</div>
				<!-- /.box-tools -->
			</div>


			<!-- /.box-header -->
			<div class="box-body per-info">
				<marquee scrollamount="2" id="scroll_news" direction="up"><div class="mrq purch" onmouseover="document.getElementById('scroll_news').stop();" onmouseout="document.getElementById('scroll_news').start();" style="height:215px;">

					<div class="box-body" style="display:block;">
						<div class="table-responsive">

							<ul class="products-list product-list-in-box">

								<?php for($i=0; $i<count($rsOfferData); $i++) { ?>  


									<li class="item" data-toggle="modal" data-target="#modal-default-<?php echo $rsOfferData[$i]['offerid'];?>">
										<div class="product-img">


											<img src="<?php echo OFFER_BANNER_ROOT.$rsOfferData[$i]['offer_image']?>" alt="Profile Image" style="    width: 125px;height: 60px;border: 1px solid #d0cece;padding: 2px;">
										</div>
										<div class="product-info" style="
										margin-left: 150px;
										">
										<a href="customers.html?v=list&amp;cid=174&amp;tid=3af614969964b58dff9ec296f454ed43&amp;Industrys=18" class="product-title"><?php echo $rsOfferData[$i]['title'];?>                    


										<span class="label label-success pull-right"> <?php echo date("d/m/Y H:i A",strtotime($rsOfferData[$i]['startdate']));?> </span>
										<br>
										<span class="  label label-danger pull-right"><?php echo date("d/m/Y H:i A",strtotime($rsOfferData[$i]['enddate'])) ; ?></span>

									</a>


									<b class="scor">Value – in terms of Bonus Points <small class="label bg-blue"> <?php echo $rsOfferData[$i]['epoint'];?> </small></b> <br>



									<b class="scor">Status -<span class="label bg-green"> <?php if($rsOfferData[$i]['active'] == 'Y') echo 'Active'; else echo 'Not Active';?> </span></b> 



								</div>
							</li>



						<?php } ?>









					</ul>

				</div>

			</div>



		</div></marquee>
	</div>
	<!-- /.box-body -->
</div>
<!-- /.box -->
</div>







</div>


<div class="modal fade in new_user_c " id="creat_new_user" style="display: none; padding-right: 17px;">
	<div class="modal-dialog">
		<div class="modal-content">
			<div class="modal-header">
				<button type="button" class="close" data-dismiss="modal" aria-label="Close">
					<span aria-hidden="true">×</span></button>
					<h4 class="modal-title">Creat New User</h4>
				</div>
				<div class="modal-body">

					<div class="x_content">

						<form class="form-horizontal form-label-left" novalidate name="createUserForm" method="post" id="createUserForm" action="" enctype="multipart/form-data" >



							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUserName">Name<span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input id="addUserName" class="form-control col-md-7 col-xs-12" name="addUserName" autocomplete="off" placeholder="both name(s) e.g Jon Doe" required="required" type="text" value="">
								</div>
							</div> 

							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUsernameMain">Username <span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input id="addUsernameMain" class="form-control col-md-7 col-xs-12" autocomplete="off" name="addUsernameMain" placeholder="both name(s) e.g Jon.Doe" required="required" type="text" >
									<div id="checkuser"></div>
									<div id="checkuserload" style="display:none;">
										<img src="http://kalpeshpc/newdemo.beatleanalytics.com/assets/img/loader.gif" width="30">
									</div>
								</div>
							</div>
							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUserEmail">Email <span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="email" id="addUserEmail" name="addUserEmail" autocomplete="off" required="required" class="form-control col-md-7 col-xs-12" >
								</div>
							</div>
							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUserEmail2">Confirm Email <span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="email" id="addUserEmail2" name="confirm_email" autocomplete="off" data-validate-linked="addUserEmail" required="required" class="form-control col-md-7 col-xs-12"  >
								</div>
							</div>
							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUserPhone">Mobile Number <span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="tel" id="addUserPhone" name="addUserPhone" autocomplete="off" required="required" data-validate-length-range="8,20" class="form-control col-md-7 col-xs-12" >
								</div>
							</div>


							<div class="item form-group">
								<label for="addUserPassword" class="control-label col-md-3">Password</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input id="addUserPassword" type="password" autocomplete="off" name="addUserPassword" data-validate-length="6,8" class="form-control col-md-7 col-xs-12" required="required">
								</div>
							</div>
							<div class="item form-group">
								<label for="password2" class="control-label col-md-3 col-sm-3 col-xs-12">Repeat Password</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input id="password2" type="password" name="password2" data-validate-linked="addUserPassword" class="form-control col-md-7 col-xs-12" required="required" >
								</div>
							</div>



							<div class="item form-group">
								<label class="control-label col-md-3 col-sm-3 col-xs-12" for="addUserGroup">Group <span class="required">*</span>
								</label>
								<div class="col-md-6 col-sm-6 col-xs-12">

									<select data-validate-linked="addUserGroup" class="form-control col-md-7 col-xs-12" required="required" id="addUserGroup" name="addUserGroup">
										<option>Select User Group</option>

										<option label="Manager" value="manager" >Manager</option>
										<option label="Line Manager" value="line_manager" >Line Manager</option>

									</select>

								</div>
							</div>

							<div class="item form-group" style=" display:none" id="ownerDiv">
								<label for="addUserPassword" class="control-label col-md-3">Organization Name</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="text" name="addOrgname" id="addOrgname" autocomplete="off" placeholder="eg. Name" class="form form-control ng-pristine ng-untouched ng-invalid ng-invalid-required ng-valid-pattern" value="">
									<input type="hidden" name="mainOrgId" id="mainOrgId">
									<input type="hidden" name="orgid_edit" id="orgid_edit" value="0">

									<div id="dataajaxorg"></div>
									<div id="ownerload" style="display:none;">
										<img src="http://kalpeshpc/newdemo.beatleanalytics.com/assets/img/loader.gif" width="30">
									</div>	
									<div style="width:100%;margin-top:20px;" id="checkpermis">
										<div class="icheckbox_flat-green" style="position: relative; float:left;  ">
											<input name="dashboard"  id="dashboard" value="d1" class="flat" data-parsley-multiple="hobbies" style="position: absolute; opacity: 0;" type="checkbox"> Dashboard
										</div>
										<div class="icheckbox_flat-green" style="position: relative; float:left; margin-left:100px;">
											<input name="ticket"  id="ticket" value="t1" class="flat" data-parsley-multiple="hobbies" style="position: absolute; opacity: 0;" type="checkbox"> Ticket
										</div>
										<div class="icheckbox_flat-green" style="position: relative; float:left; margin-left:100px;">
											<input name="report"  id="report" value="r1" class="flat" data-parsley-multiple="hobbies" style="position: absolute; opacity: 0;" type="checkbox"> Report
										</div>
										<div class="icheckbox_flat-green" style="position: relative; float:left; margin-left:100px;">
											<input name="feedback"  id="feedback" value="f1" class="flat" data-parsley-multiple="hobbies" style="position: absolute; opacity: 0;" type="checkbox"> Feedback
										</div>
									</div>
								</div>

							</div>

							<div class="item form-group" style="display:none;" id="managerDiv">
								<label for="addUserPassword" class="control-label col-md-3">Branch Name</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="text" name="addBranchname"  autocomplete="off" id="addBranchname" placeholder="eg. Name" class="form form-control ng-pristine ng-untouched ng-invalid ng-invalid-required ng-valid-pattern" value="">
									<input type="hidden" name="mainBraId" id="mainBraId">
									<input type="hidden" name="branchid_edit" id="branchid_edit" value="0">
									<div id="dataajaxbranch"></div>
									<div id="Mangerload" style="display:none;">
										<img src="http://kalpeshpc/newdemo.beatleanalytics.com/assets/img/loader.gif" width="30">
									</div>
								</div>

							</div>


							<div class="item form-group" style=" display:none;" id="managerLinemana">
								<label for="addUserPassword" class="control-label col-md-3">Industry Name</label>
								<div class="col-md-6 col-sm-6 col-xs-12">
									<input type="text" name="addIndname" autocomplete="off" id="addIndname" placeholder="eg. Name" class="form form-control ng-pristine ng-untouched ng-invalid ng-invalid-required ng-valid-pattern" value="">
									<input type="hidden" name="ajaxIndId" id="ajaxIndId">
									<input type="hidden" name="indid_edit" id="indid_edit" value="0">
									<div id="dataajaxInd"></div>
									<div id="Lineload" style="display:none;">
										<img src="http://kalpeshpc/newdemo.beatleanalytics.com/assets/img/loader.gif" width="30">
									</div>
								</div>
							</div>




							<div class="form-group">
								<div class="col-md-6 col-md-offset-3">
									<button type="submit" class="btn btn-primary">Cancel</button>
									<input type="submit" class="btn btn-success" name="addusersubmit" id="addusersubmit" value="Submit">
								</div>
							</div>

						</form>

						<script>
							$(document).ready(function(){
								$("#addUserGroup").change(function(){

									var selectval = $("#addUserGroup").val();

									if (selectval == 'owner')
									{
										$("#guestloginDiv").show('100');
										$("#ownerDiv").show('100');
										$("#checkpermis").show('100');
										$("#managerLinemana").hide('100');
										$("#managerDiv").hide('100');
										$("#linemanagerKeyword1").hide('100');
										$("#linemanagerKeyword2").hide('100');
										$("#linemanagerKeyword3").hide('100');				
									}
									else if (selectval == 'manager')
									{
										$("#managerDiv").show('100');
										$("#guestloginDiv").hide('100');
										$("#ownerDiv").show('100');
										$("#checkpermis").hide('100');
										$("#managerLinemana").hide('100');
										$("#linemanagerKeyword1").hide('100');
										$("#linemanagerKeyword2").hide('100');
										$("#linemanagerKeyword3").hide('100');
									}
									else if (selectval == 'line_manager')
									{
										$("#managerLinemana").show('100');
										$("#guestloginDiv").hide('100');
										$("#ownerDiv").show('100');
										$("#checkpermis").hide('100');
										$("#managerDiv").show('100');
										$("#linemanagerKeyword1").show('100');
										$("#linemanagerKeyword2").show('100');
										$("#linemanagerKeyword3").show('100');		
									}
									else 
									{
										$("#guestloginDiv").hide('100');
										$("#managerLinemana").hide('100');
										$("#ownerDiv").hide('100');
										$("#checkpermis").hide('100');
										$("#managerDiv").hide('100');
										$("#linemanagerKeyword1").hide('100');
										$("#linemanagerKeyword2").hide('100');
										$("#linemanagerKeyword3").hide('100');   
									}
								});



							})


						</script>



					</div>

				</div>

			</div>
			<!-- /.modal-content -->
		</div>
		<!-- /.modal-dialog -->
	</div>		

</div>
<?php //} ?>	
<!------//10-7-2018------------->

<?php if($_SESSION['UserInfo']['UType'] == 'owner') { ?> 

<?php } ?>		  

<!-----------------------owner---end--------------------------------------------------------------------------------------end---------------------------------------------------------------------------------end--------------------------------------------------------------------------------end-------------------------------------------------------------------------------->

<!---------------------end_user_profile------------------------------------------->
<?php if($_SESSION['UserInfo']['UType'] == 'End_user') { ?> 

	<section class="what_we_provide_row" id="What-We-Provide">

		<div class="beatle_logo_bg container---">

			<div class="row----">
				<br>


				<div class="col-md-4 col-lg-4 pr_top">

					<div class="profile_corpo end_u_pic">
						<div class="profile_pic">
							<ul class="img-list1 tabbing"> 
								<li class="pull-center image" style="width:138px !IMPORTANT;">
									<img id="UserWebImage_" src="<?php echo $ProfileImage; ?>" class="img-responsive " alt="User Image" style="    border-radius: 100%;">
									<a href="#popup_upload_" data-toggle="modal" data-target="#popup_upload">
										<span class="text-content1"><span><strong>Change <br>Image</strong></span></span>
									</a>
								</li>                          
							</ul></div>
							<h2> <?php echo $uInfo___[0]['db_username']?></h2>
							<h5><?php echo $uInfo___[0]['db_aboutme']?></h5>
							<div class="edit_btn">

								<a href="profilenew.html?v=edit" class="btn btn-primary btn-md">Edit Profile</a>
							</div>

						</div>
					</div>


					<div class="col-md-4 col-lg-4 beatle_point">
						<h1><?php echo $totalPoints =  $objProfile->fetchTotalBonus();?></h1>
						<div class="col-md-6"><button data-target="#pwdModal" data-toggle="modal" class="pull-left end_u_btn bt_lf">Redeem</button></div>
						<div class="col-md-6"><button  data-target="#pwdModal2" data-toggle="modal" class="pull-right end_u_btn"  >Purchase</button></div>

					</div>

					<div class="col-md-4 col-lg-4 point_stare">
						<img src="theme/black/images/beatle_point_stare.png">
					</div>
					<hr>
					<div class="per_info">
						<h1>Personal Information</h1>
						<br>
						<div class="col-md-4">
							<p><span><i class="fa fa-id-badge"></i></span><span class="pr_title"> Profile id :</span><span><?php echo $uInfo___[0]['db_userLoginName']?></span></p>
							<p><span><i class="fa fa-user"></i></span><span class="pr_title">  Full Name :</span><span><?php echo $uInfo___[0]['db_username']?></span></p>
							<p><span><i class="fa fa-envelope" aria-hidden="true"></i></span> <span class="pr_title">  Email id:</span><span><?php echo $uInfo___[0]['db_email']?></span></p>
							<p><span><i class="fa fa-mobile"></i></span> <span class="pr_title">  no :</span><span><?php echo $uInfo___[0]['db_phone']?></span></p>
							<p> <span><i class="fa fa-address-card"></i></span> <span class="pr_title"> Address  :</span><span><?php echo $uInfo___[0]['db_address']?></span></p>

							<p> <span><i class="fa fa-file-archive-o"></i></span> <span class="pr_title">  PIN Code :</span>  <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_pincode']?></span><span class="edit"></span></p>
							
							
							<?php 
							$st = '';
							if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
								$SQL = "SELECT * FROM states where id = ".$uInfo___[0]['db_state']." order by name ASC ";
								$rsStates_ = $objDB->sql_query($SQL);
								$st = $rsStates_[0]['name'];
							}


							$ct = '';
							if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
								$SQL = "SELECT * FROM cities where id = ".$uInfo___[0]['db_city']." order by name ASC ";
								$rsCity_ = $objDB->sql_query($SQL);
								$ct = $rsCity_[0]['name'];
							}
							?>
							
							<p> <span><i class="fa fa-flag"></i></span><span class="pr_title">  State  :  </span><span id="lblName" class="editable"><?php echo $st?></span></p>
							<p> <span><i class="fa fa-building"></i></span> <span class="pr_title"> City  :  </span><span id="lblName" class="editable"><?php echo $ct?></span></p>

						</div>

						<div class="col-md-8">
							<div class="point_redeem_process">
								<img src="theme/black/images/process_b_point.png">
							</div>
						</div>

						<div class="" style="clear: both;"></div>


						<div class="round_marq">
							<div class="col-md-4"></div>
							<div class="col-md-4">
								<div class="box box-warning box-solid">
									<div class="box-header with-border pr_hed">
										<h3 class="box-title">Last five visit</h3>

										<div class="box-tools pull-right">
											<button type="button" class="btn btn-box-tool waves-effect waves-circle waves-light" data-widget="collapse"><i class="fa fa-minus"></i>
											</button>
										</div>

									</div>

									<div class="box-body per-info">


										<marquee scrollamount="2" id="scroll_news1" direction="up"><div class="mrq" onmouseover="document.getElementById('scroll_news1').stop();" onmouseout="document.getElementById('scroll_news1').start();" style="height:215px;">

											<div class="table-responsive">
												<?php $rsVisit = $objProfile->fetchCustomerVisit(); ?>
												<table class="table no-margin">
													<thead>
														<tr>
															<th>Date</th>
															<th>Organization</th>
															<th>Location</th>
															<th>Type</th>
															<th>Rating</th>
														</tr>
													</thead>
													<?php
													if(count($rsVisit) > 0) {
														$cnt = count($rsVisit);
														if($cnt < 5)
															$cnt = 5;

														for($i=0;$i<$cnt; $i++) {

															if($i < count($rsVisit)) {
																?>
																<tr>
																	<td><a href="cusers.html?back=profilenew&v=list&cid=<?php echo $rsVisit[$i]['userId'];?>&tid=<?php echo $rsVisit[$i]['tokenid'];?>&Industrys=<?php echo $rsVisit[$i]['db_surveyIndId'];?>"><?php echo date("d/m/Y",strtotime($rsVisit[$i]['created_date']));?></a></td>
																	<td><?php echo $objProfile->FetchOrganizationName($rsVisit[$i]['orgid']);?></td>
																	<td><span class=""><?php echo $objProfile->FetchBranchName($rsVisit[$i]['db_surveyBranchid']);?></span></td>
																	<td><span class=""><?php echo $objProfile->FetchIndustryName($rsVisit[$i]['db_surveyIndId']);?></span></td>
																	<td><span class=""><?php echo $objProfile->fetchCustomerRating($rsVisit[$i]['userId'],$rsVisit[$i]['tokenid']);?></span></td>
																</tr>
															<?php } else{  ?>
																<tr>
																	<td>&nbsp;</td>
																	<td>&nbsp;</td>
																	<td>&nbsp;</td>
																	<td>&nbsp;</td>
																</tr>
																<?php
															}
														}
													} else{
														?>
														<tr>
															<td colspan="10" align="center"> No any visit recoed found.</td>
														</tr>
														<?php
													}?>
												</table>
											</div>
											<!----<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 05/03/2018<span>point - <b> 12</b></span></p>

											<p> 05/03/2018<span>point - <b> 12</b></span></p>-->

										</div></marquee>
									</div>

								</div>

							</div>

							<div class="col-md-4">
								<div class="box box-warning box-solid">
									<div class="box-header with-border pr_hed">
										<h3 class="box-title">Last five Orders</h3>

										<div class="box-tools pull-right">
											<button type="button" class="btn btn-box-tool waves-effect waves-circle waves-light" data-widget="collapse"><i class="fa fa-minus"></i>
											</button>
										</div>

									</div>

									<div class="box-body per-info">


										<marquee scrollamount="2" id="scroll_news1" direction="up"><div class="mrq" onmouseover="document.getElementById('scroll_news1').stop();" onmouseout="document.getElementById('scroll_news1').start();" style="height:218px;">


											<div class="table-responsive">
												<table class="table no-margin">
													<thead>
														<tr>
															<th class="text-center">Order ID</th>
															<th class="text-center">Product Name</th>
															<th class="text-center">Quantity</th>
															<th class="text-center">Status</th>
															<th class="text-center">Created Date</th>
														</tr>
													</thead>
													<tbody>
														<?php 

								//print_r($_SESSION);
								//echo "<pre>";
								//print_r($rsCustomerInfo);
								//echo "</pre>";

														$rsOrderData = $objProfile->fetchOrderDetails();
														if(count($rsOrderData)>0){



															for ($i=0;$i< count($rsOrderData);$i++)
															{

																?>
																<tr>
																	<td><?php echo $rsOrderData[$i]['orderuid']; ?></td>
																	<td><?php echo $rsOrderData[$i]['productname']; ?></td>
																	<td><?php echo $rsOrderData[$i]['quantity']; ?></td>
																	<td><?php echo $rsOrderData[$i]['status']; ?></td>
																	<td><?php echo date("d/m/Y H:i A",strtotime($rsOrderData[$i]['created_date'])); ?></td>
																</tr>
															<?php }
														}else{
															?>
															<tr>
																<td colspan="10" align="center"> No any data found. </td>
															</tr>
														<?php } ?>
													</tbody>
												</table>
											</div>

											<!--<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 09/04/2018<span>point - <b> 0</b></span></p>

											<p> 05/03/2018<span>point - <b> 12</b></span></p>

											<p> 05/03/2018<span>point - <b> 12</b></span></p>--->

										</div></marquee>
									</div>

								</div>

							</div>
						</div>

					</div>





					<div class="col-md-12">

					</div>

				</div>		




			</div>

		</div>



	</section>






	<style>

	.per_info p i {
		width: 38px;
		height: 29px;
		font-size: 25px;
		text-align: left;
	}

	.round_marq {
		margin-top: -164px;
		width: 100%;
		float: left;
	}
	.profile_corpo.end_u_pic {
		background: #3c8dbc;

	}
	.point_redeem_process {
		text-align: left;
		margin: 0px;
		margin-top: -68px;
	}
	.point_redeem_process img {
		width: 686px;
	}
	.per_info p {
		font-size: 20px;
		margin-left:0px;
		color: black;
	}

	.beatle_point h1 {
		font-family: French Script MT;
		font-size: 228px;
		text-align: center;
		height: auto;
		margin-top: 0px;
		color: #08569e;
	}
	.point_stare img {
		width: 433px;
		margin-top: 21px;
	}
	button.end_u_btn {
		padding: 8px 53px;
		border-radius: 25px;
		border: none;
		background: #a3d39c;
		color: #FFF;
		font-size: 23px;
	}
	button.end_u_btn.bt_lf {
		float: right;
	}

	.beatle_logo_bg {
		background-image: url(theme/black/images/pro_backg_pic.png);
		background-size: 100%;
		height: auto !IMPORTANT;
		float: left;
		width: 100%;
	}

	.per_info h1 {
		color: #08569e;
		font-weight: 600;
		width: 78%;
		float: left;
		border-top: 3px solid #DDD;
		margin-top: -99px;
		padding-left: 12px;
		padding-top: 27px;
	}
	button.pull-left.end_u_btn.bt_lf {
		float: right !IMPORTANT;
	}
	button.pull-right.end_u_btn {
		float: left !IMPORTANT;
	}

</style>		

<?php } ?>	



<!---------------------end_user_profile------------------------------------------->				



<!-----old_owner_and_end_user_profile_----->
<div class="" style="display:none;">
	<div class="col-md-12 col-sm-12 col-xs-12">  
		<div class="profile-name"><span class="welcome-name"><h1>Welcome <?php echo $uInfo___[0]['db_username']?></h1></span></div>

		<span  id="lblName" class="editable about-me cust" ><?php echo $uInfo___[0]['db_aboutme']?></span>	

		<div class="edit-profile pull-right cust">

			<!--<button type="button"  id="edit"></button> -->
			<a href="profilenew.html?v=edit" class="btn btn-primary btn-md">Edit Profile</a>

		</div> 
	</div>

	<div class="col-md-12 col-sm-12 col-xs-12 ">
		<div class="col-md-3 col-sm-3 col-xs-12 profile-left">
			<div class="profile-img">


				<ul class="img-list1">


					<li class="customer-profile" style="width:75%; height:auto;">
						<img id="UserWebImage_" src="<?php echo $ProfileImage; ?>" class="img-responsive " alt="User Image">
						<a href="#popup_upload_" data-toggle="modal" data-target="#popup_upload">
							<span class="text-content1 cust-chang-img" style="width:100%; border-radius:11px 11px 0 0; height:45px;"><span><strong>Change Image</strong></span></span>

						</a>

					</li> 


				</ul>

			</div>

			<div class="personal-details">
				<div class="panel-default">
					<div class="panel-body form-horizontal payment-form" style="padding-bottom: 0px;">
						<div class="form-group">
							<div class="col-md-12 col-sm-12 col-xs-12 complit-pro">
								<p>Profile id :   <span><?php echo $uInfo___[0]['db_userLoginName']?></span></p>
								<p>Full Name  :   <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_username']?></span> </p>
								<p>Email id   :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_email']?></span></p>
								<p>Phone no   :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_phone']?></span></p>
								<p>Address    :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_address']?></span></p>


								<p>PIN Code :  <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_pincode']?></span><span class="edit"></span></p>

								<?php 
								$st = '';
								if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
									$SQL = "SELECT * FROM states where id = ".$uInfo___[0]['db_state']." order by name ASC ";
									$rsStates_ = $objDB->sql_query($SQL);
									$st = $rsStates_[0]['name'];
								}


								$ct = '';
								if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
									$SQL = "SELECT * FROM cities where id = ".$uInfo___[0]['db_city']." order by name ASC ";
									$rsCity_ = $objDB->sql_query($SQL);
									$ct = $rsCity_[0]['name'];
								}
								?>

								<p>State  :  <span  id="lblName" class="editable" ><?php echo $st?></span></p>
								<p>City  :  <span  id="lblName" class="editable" ><?php echo $ct?></span></p>
								<!--   <p>About Me  : <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_aboutme']?></span></p>-->


							</div>
						</div>
					</div>            
					<!-- / panel preview -->


				</div>
			</div>



			
			
			
		</div>
		<style>
		span.chng-pic {
			background: #222d328a;
			width: 94%;
			/* float: left; */
			position: absolute;
			text-align: center;
			margin: 0 auto;
			bottom: 46px;
			left: 10px;
			padding: 8px 0;
			font-size: 25px;
			color: white;
			display: none;
		}
		.profile-img:hover span.chng-pic {
			display: block;
		}


	</style>

	<?php if($_SESSION['UserInfo']['UType'] == 'End_user') { ?>    

		<div class="col-md-9 profile-box cus-pro">


			<div class="small-boxs bx-box footer-box " >
				<div class="box-header with-border box-header headline">
					<h3 class="box-title"> <img src="theme/black/images/bonus-points.png">&nbsp;&nbsp;My Bonus Points</h3>


				</div>

				<div class="" style="clear:both;"></div>
				<div class="box-body map cust" style="height:auto;">
					<div class="news-manu skill-bar">
						<div class="tab-pane <?php if($objProfile->back == 'tab_2') echo 'active';?>" id="tab_2">
							<div class="container" style="width:100%; margin:17px 0px;">
								<div class="my-bounes-point">


									<div class="col-lg-6 bonas-main">
  <!---<div class="my-point"><p><img src="theme/black/images/bonus-points-big.png"><?php echo $totalPoints =  $objProfile->fetchTotalBonus();?></p></div>
  <p class="f-bounes"><i><?php echo ucwords(number_to_word($totalPoints));
  
  ?></i></p>-->
  
  <div class="bonas-pint-round">
  	<div class="bonus-point">
  		<div class="coin">
  			<div class="face heads">
  				<?php echo $totalPoints =  $objProfile->fetchTotalBonus();?>
  			</div>
  			<div class="face tails">
  				<?php echo $totalPoints =  $objProfile->fetchTotalBonus();?>
  			</div>
  		</div>
  	</div>
  	<p class="f-bounes"><i><?php echo ucwords(number_to_word($totalPoints));?></i></p>




  </div>
  
  
  
  
</div>



<div class="col-lg-6 bonas-main">
	<div class="pur">


		<!-----------redem -popup------------------>

		<a href="#" data-target="#pwdModal" data-toggle="modal" class="col-md-5 pull-left"> <button type="button"  >Offer Redeem</button></a>


		<a href="#" data-target="#pwdModal2" data-toggle="modal" class="col-md-6 pull-right"> <button type="button"  >Product Redeem</button></a>


		
		<!------poup-forget-pass--end----->






	</div>

	<div class="col-lg-12 bonus-points-text" style="margin-top:60px;">
		<p><i>Enjoy with Bonus Points by Beatle Analytics. Bonus Point Rewards has something for everyone. The only feedback
		rewards program that has the simplest way to earn rewards and many carefully selected, exciting rewards for you.</i></p>
	</div>
	
</div>

</div>
<br>
</div>
</div>
</div>
</div>

</div>

<div class="redeem-process"><img src="theme/black/images/redeem-process.png"></div>

</div>

<!---total visit test--->
	<!--<div class="total footer">
	 
	 
	 <div class="col-md-3 ">
	 <div class="total visit">
	 <img src="theme/black/images/images.png">
	  <P>40</P>
	 <div class="footer-total visit">Total visit</div>
	 </div>
	 </div>
	 
	 <div class="col-md-3 total order">
	 <img src="theme/black/images/order.png">
	  <P>5</P>
	 <div class="footer-total order">Total order</div>
	 </div>
	
	</div>--->
	<div style="clear:both;"></div>
	<br>
	<div class="">
		<div class="col-md-6 cus-pro">
			<div class="small-boxs">
				<div class="box-header with-border headline">
					<h3 class="box-title">Last five visit</h3>
					<div class="box-tools pull-right" style="margin:8px 0px;"> <a href="cusers.html?v=list&tab=tab_1"> <span class="label label-success">View All Visit</span></a> </div>
				</div>
				<!-- /.box-header -->
				<div class="box-body">
					<div class="table-responsive">
						<?php $rsVisit = $objProfile->fetchCustomerVisit(); ?>
						<table class="table no-margin">
							<thead>
								<tr>
									<th>Date</th>
									<th>Organization</th>
									<th>Location</th>
									<th>Type</th>
									<th>Rating</th>
								</tr>
							</thead>
							<?php
							if(count($rsVisit) > 0) {
								$cnt = count($rsVisit);
								if($cnt < 5)
									$cnt = 5;

								for($i=0;$i<$cnt; $i++) {

									if($i < count($rsVisit)) {
										?>
										<tr>
											<td><a href="cusers.html?back=profilenew&v=list&cid=<?php echo $rsVisit[$i]['userId'];?>&tid=<?php echo $rsVisit[$i]['tokenid'];?>&Industrys=<?php echo $rsVisit[$i]['db_surveyIndId'];?>"><?php echo date("d/m/Y",strtotime($rsVisit[$i]['created_date']));?></a></td>
											<td><?php echo $objProfile->FetchOrganizationName($rsVisit[$i]['orgid']);?></td>
											<td><span class=""><?php echo $objProfile->FetchBranchName($rsVisit[$i]['db_surveyBranchid']);?></span></td>
											<td><span class=""><?php echo $objProfile->FetchIndustryName($rsVisit[$i]['db_surveyIndId']);?></span></td>
											<td><span class=""><?php echo $objProfile->fetchCustomerRating($rsVisit[$i]['userId'],$rsVisit[$i]['tokenid']);?></span></td>
										</tr>
									<?php } else{  ?>
										<tr>
											<td>&nbsp;</td>
											<td>&nbsp;</td>
											<td>&nbsp;</td>
											<td>&nbsp;</td>
										</tr>
										<?php
									}
								}
							} else{
								?>
								<tr>
									<td colspan="10" align="center"> No any visit recoed found.</td>
								</tr>
								<?php
							}?>
						</table>
					</div>
					<!-- /.table-responsive --> 
				</div>
				<!-- /.box-body --> 

			</div>
		</div>
		<div class="col-md-6 cus-pro">
			<div class="small-boxs">
				<div class="box-header with-border headline">
					<h3 class="box-title">Last five Orders</h3>
					<div class="box-tools pull-right" style="margin:8px 0px;"> <a href="cusers.html?v=list&tab=tab_2"> <span class="label label-danger">View All Orders</span></a> </div>
				</div>
				<!-- /.box-header -->
				<div class="box-body">
					<div class="table-responsive">
						<table class="table no-margin">
							<thead>
								<tr>
									<th class="text-center">Order ID</th>
									<th class="text-center">Product Name</th>
									<th class="text-center">Quantity</th>
									<th class="text-center">Status</th>
									<th class="text-center">Created Date</th>
								</tr>
							</thead>
							<tbody>
								<?php 
								
								//print_r($_SESSION);
								//echo "<pre>";
								//print_r($rsCustomerInfo);
								//echo "</pre>";
								
								$rsOrderData = $objProfile->fetchOrderDetails();
								if(count($rsOrderData)>0){



									for ($i=0;$i< count($rsOrderData);$i++)
									{

										?>
										<tr>
											<td><?php echo $rsOrderData[$i]['orderuid']; ?></td>
											<td><?php echo $rsOrderData[$i]['productname']; ?></td>
											<td><?php echo $rsOrderData[$i]['quantity']; ?></td>
											<td><?php echo $rsOrderData[$i]['status']; ?></td>
											<td><?php echo date("d/m/Y H:i A",strtotime($rsOrderData[$i]['created_date'])); ?></td>
										</tr>
									<?php }
								}else{
									?>
									<tr>
										<td colspan="10" align="center"> No any data found. </td>
									</tr>
								<?php } ?>
							</tbody>
						</table>
					</div>
					<!-- /.table-responsive --> 
				</div>
				<!-- /.box-body --> 

			</div>
		</div>
	</div>
	<style>
	
	
	
</style>
<!---//total visit test--->

<?php }else{ ?>



	<div class="col-md-9 col-sm-9 col-xs-12"> 
		<!-- panel preview -->
		<div class="panel-default">
			<div class="panel-body form-horizontal payment-form ">
				<div class="form-group"> 

                  <!--<div class="col-md-12 col-sm-12 col-xs-12 complit-pro owner">
                    <p>Profile id:   <span><?php echo $uInfo___[0]['db_userLoginName']?></span></p>
                    <p>Full Name  :   <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_username']?></span> </p>
                    <p>Email id   :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_email']?></span></p>
                    <p>Phone no   :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_phone']?></span></p>
                    <p>Address    :   <span id="lblName" class="editable"><?php echo $uInfo___[0]['db_address']?></span></p>
					<p>PIN Code :  <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_pincode']?></span><span class="edit"></span></p>

						
					
					
					<?php 
					$st = '';
					if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
						$SQL = "SELECT * FROM states where id = ".$uInfo___[0]['db_state']." order by name ASC ";
						$rsStates_ = $objDB->sql_query($SQL);
						$st = $rsStates_[0]['name'];
					}
					
					
					$ct = '';
					if(!empty($uInfo___[0]['db_state']) && $uInfo___[0]['db_state'] != 0) {
						$SQL = "SELECT * FROM cities where id = ".$uInfo___[0]['db_city']." order by name ASC ";
						$rsCity_ = $objDB->sql_query($SQL);
						$ct = $rsCity_[0]['name'];
					}
					?>
                    
                    <p>State  :  <span  id="lblName" class="editable" ><?php echo $st?></span></p>
                    <p>City  :  <span  id="lblName" class="editable" ><?php echo $ct?></span></p>
                    <p>About Me  : <span  id="lblName" class="editable" ><?php echo $uInfo___[0]['db_aboutme']?></span></p>
                    
                    
                </div> --> 

                <!-----20-12-2017-->

                <div class="col-md-12 profile-box cus-pro">


                	<div class="small-boxs bx-box footer-box ">
                		<div class="box-header with-border box-header headline">
                			<h3 class="box-title"> <img src="theme/black/images/bonus-points.png">&nbsp;&nbsp; Total Redeem Point By Customer</h3>


                		</div>
                		<div class="box-body map cust" style="height:auto;">
                			<div class="news-manu skill-bar">
                				<div class="tab-pane " id="tab_2">
                					<div class="container" style="width:100%; margin:17px 0px;">
                						<div class="my-bounes-point">
                							<div class="col-lg-6 bonas-main">
                             <!--- <div class="my-point"><p><img src="theme/black/images/bonus-points-big.png"><?php echo fetchTotalPointsClient();?></p></div>
                             	<p class="f-bounes"><i><?php echo ucwords(number_to_word(fetchTotalPointsClient())); ?></i></p>--->
                             	<div class="bonas-pint-round">
                             		<div class="bonus-point">
                             			<div class="coin">
                             				<div class="face heads">
                             					<?php echo fetchTotalPointsClient();?>
                             				</div>
                             				<div class="face tails">
                             					<?php echo fetchTotalPointsClient();?>
                             				</div>
                             			</div>
                             		</div>
                             		<p class="f-bounes"><i><?php echo ucwords(number_to_word(fetchTotalPointsClient())); ?></i></p>




                             	</div>

                             </div>

                             <div class="col-lg-6 bonas-main">

                             	<div class="pur">

                             		<button type="button" class="btn btn-default col-lg-5" data-toggle="modal" data-target="#modal-default-owner">
                             			Redeem
                             		</button>
                             		<div class="col-lg-2"></div>
                             		<button type="button" class="btn btn-default  purchase-email col-lg-5" data-toggle="modal" data-target="#modal-default-owner12">
                             			Purchase 
                             		</button>
                             	</div>
                             	<!--model-->


                             	<div class="col-lg-12 bonus-points-text pull-right" style="margin-top:60px;">
                             		<p><i>Enjoy with Bonus Points by Beatle Analytics. Bonus Point Rewards has something for everyone. The only feedback
                             		rewards program that has the simplest way to earn rewards and many carefully selected, exciting rewards for you.</i></p>
                             	</div>


                             </div>


                         </div>
                         <br>
                     </div>
                 </div>
             </div>
         </div>

     </div>



 </div>
 <div class="redeem-process"><img src="theme/black/images/owner-redeem-process.png"></div>


 <!--//20-12-2017------->

 <style>

					/**.complit-pro p span.edit {
    background: url(http://kalpeshpc/owner.beatleanalytics.com/theme/black/images/editar.png);
    background-size: 12px;
    background-repeat: no-repeat;
    background-position: right;
    
}
**/


.profile-name h1 {
	padding: 0px;
	margin: 0px;
}
.complit-pro.owner p {

	width: auto;
}
</style>
</div>
</div>
<!-- / panel preview --> 

</div>
</div>
<div class="Redeem-history-own">
	<div class="col-md-3 cus-pro">
		<div class="small-boxs">
			<div class="box-header with-border headline">
				<h3 class="box-title">Redeem History</h3>
				<div class="box-tools pull-right" style="margin:8px 0px;"> <a href="emailer.html?v=report"> <span class="label label-danger">View All</span></a></div>
			</div>
			<!-- /.box-header -->
			<div class="box-body">
				<div class="table-responsive">
					<table class="table no-margin">
						<thead>
							<tr>
								<th>Date</th>

								<th>Point/ Rs.</th>
							</tr>
						</thead>
						<tbody>
							<?php
							$rsRedeemData = fetchAllRedeemData();
							if(count($rsRedeemData) > 0) {
								for($rp=0; $rp<count($rsRedeemData); $rp++) {
									?>
									<tr>
										<td><?php echo date("d/m/Y",strtotime($rsRedeemData[$rp]['created_date']));?></td>
										<td><span class=""> <span>Point</span> - <?php echo $rsRedeemData[$rp]['point'];?> </span></td>
									</tr>
								<?php } 

							}else{ ?>
								<tr>
									<td colspan="2"> No any data found </td>
								</tr>
							<?php } ?>  



						</tbody>
					</table>
				</div>
				<!-- /.table-responsive --> 
			</div>
			<!-- /.box-body --> 

		</div>
	</div>

	<div class="col-md-3 cus-pro">
		<div class="small-boxs">
			<div class="box-header with-border headline">
				<h3 class="box-title">Purchase History</h3>
				<div class="box-tools pull-right" style="margin:8px 0px;"> <a href="emailer.html?v=list"> <span class="label label-danger">View All</span></a></div>
			</div>
			<!-- /.box-header -->
			<div class="box-body">
				<div class="table-responsive">
					<table class="table no-margin">
						<thead>
							<tr>
								<th>Date</th>
								<th>Status</th>
								<th>Point/ Rs.</th>
							</tr>
						</thead>
						<tbody>
							<?php
							$rsRedeemData = fetchAllPurchaseHistoryData();
							if(count($rsRedeemData) > 0) {
								for($rp=0; $rp<count($rsRedeemData); $rp++) {
									?>
									<tr>
										<td><?php echo date("d/m/Y",strtotime($rsRedeemData[$rp]['created_date']));?></td>
										<td><span class=""><?php echo $rsRedeemData[$rp]['status'];?> </span></td>
										<td><span class=""> <span>Rs</span> - <?php echo $rsRedeemData[$rp]['totalprice'];?>/- </span></td>
									</tr>
								<?php } 

							}else{ ?>
								<tr>
									<td colspan="2"> No any data found </td>
								</tr>
							<?php } ?>  



						</tbody>
					</table>
				</div>
				<!-- /.table-responsive --> 
			</div>
			<!-- /.box-body --> 

		</div>
	</div>


</div>

<div class="col-md-3 cus-pro">
	<div class="small-boxs">
		<div class="box-header with-border headline">
			<h3 class="box-title">Subscription Email</h3>

		</div>
		<!-- /.box-header -->
		<div class="box-body" style="height: 250px;">
			<div class="table-responsive">
				<div class="col-lg-12 bonas-main">
					<div class="my-point"><p class="subscrib-email"><i class="fa fa-envelope" aria-hidden="true"></i>&nbsp;<?php echo fetchRemainPointClient('email');?></p></div>
					<p class="f-bounes"><i><?php echo ucwords(number_to_word(fetchRemainPointClient('email'))); ?></i></p>
				</div>
			</div>
			<!-- /.table-responsive --> 
		</div>
		<!-- /.box-body --> 

	</div>
</div>

<div class="col-md-3 cus-pro">
	<div class="small-boxs">
		<div class="box-header with-border headline">
			<h3 class="box-title">Subscription SMS</h3>

		</div>
		<!-- /.box-header -->
		<div class="box-body" style="height: 250px;">
			<div class="table-responsive">
				<div class="col-lg-12 bonas-main">
					<div class="my-point"><p><i class="fa fa-commenting-o" aria-hidden="true"></i>&nbsp;0 000000000000000000</p></div>
					<p class="f-bounes"><i>Zero</i></p>
				</div>
			</div>
			<!-- /.table-responsive --> 
		</div>
		<!-- /.box-body --> 

	</div>
</div>







<?php } ?>
<script>
	$(function() {
		$('#profile-image1').on('click', function() {
			$('#profile-image-upload').click();
		});
	});       
</script> 
<script> 
	$(document).ready(function(){
		$("#flip").click(function(){
			$("#panel").slideToggle("slow");
		});
	});
</script>












<script>

	function validatEamilRequest(){
		var pt = document.getElementById('email_request').value.trim();

		if( parseInt(pt) <= 0) {
			document.getElementById('email_request').style.border = '1px solid red';
			return false;
		}

		var xhttp12 = new XMLHttpRequest();
		xhttp12.onreadystatechange = function() {
			if (xhttp12.readyState == 4 && xhttp12.status == 200) {
				if(xhttp12.responseText == 0){
					alert('Your email purchase request has been added successfuly, we will contact you soon !');
					window.location.href = 'profilenew.html';
				}else 
				if(xhttp12.responseText == 1){
					alert('Oops, Here is something wrong to add email purchase request, please try agai!');
					window.location.href = 'profilenew.html';
				}
			}
		};
		xhttp12.open("GET", "runajax.php?acn=insertemailrequest&point="+pt, true);
		xhttp12.send();
	}

	function redeem_point_client(){
		var pt = document.getElementById('total_redeem_point').value.trim();
		var number_val = document.getElementById('number_val');
		var nval = parseInt(number_val.value.trim());
						//alert(number_val.value.trim() +" = "+ pt);
						//return false;
						
						/*
						if( number_val.value.trim() == 0 ){
							number_val.style.border = '1px solid red';
							return false;
						}else*/ 
						if( nval >= parseInt(pt)) {
							number_val.style.border = '1px solid red';
							return false;
						}else{
							number_val.style.border = '1px solid #ddd';
						}
						
						var xhttpxx = new XMLHttpRequest();
						xhttpxx.onreadystatechange = function() {
							if (xhttpxx.readyState == 4 && xhttpxx.status == 200) {
								if(xhttpxx.responseText == 0){
									alert('Your bonus point redeemed successfuly with email!');
									window.location.href = 'profilenew.html';
								}else 
								if(xhttpxx.responseText == 1){
									alert('Oops, You dont have sufficient redeemable point!');
									window.location.href = 'profilenew.html';
								}
							}
						};
						xhttpxx.open("GET", "runajax.php?acn=total_redeem_point&point="+nval, true);
						xhttpxx.send();
						
						
						
					}
					function openCity(evt, cityName) {
						var i, tabcontent, tablinks;
						tabcontent = document.getElementsByClassName("tabcontent");
						for (i = 0; i < tabcontent.length; i++) {
							tabcontent[i].style.display = "none";
						}
						tablinks = document.getElementsByClassName("tablinks");
						for (i = 0; i < tablinks.length; i++) {
							tablinks[i].className = tablinks[i].className.replace(" active", "");
						}
						document.getElementById(cityName).style.display = "block";
						evt.currentTarget.className += " active";
					}

                    // Get the element with id="defaultOpen" and click on it
                    document.getElementById("defaultOpen").click();
                </script>

            <?php } ?>
        </div>

    </div>
</div>


</div>
</div>
</div>
</div>
</section>
</div>


<!----TOOLTIP PRICE-->
<script>
	$(document).ready(function(){
		$('[data-toggle="popover"]').popover();   
	});
</script>





<script>
	$(document).ready(function(e) {
		$('#email_request').keyup(function(){
			
			var req = parseInt($(this).val());
			if(req < 0 || req == '' || isNaN(req)){
				$(this).val(0);
				req = 0;
				//return false;
			}
			
			var paisa = req * .04;
			var tax =  (paisa * 18 / 100);
			tax = tax.toFixed(2)
			var rs = (parseFloat(paisa)+parseFloat(tax));
			rs = rs.toFixed(2)
			
			$('#total-rs').html('<p class="pull-right">'+req+' Email X .04 Paisa = <span class="pull-right">'+paisa+'</span></p><p class="pull-right">18% Tex = <span class="pull-right">'+tax+'</span></p><p class="pull-right total-price">Total Rs. = <span class="pull-right">'+rs+'</span></p>');
			
			/*var xhttp12 = new XMLHttpRequest();
			xhttp12.onreadystatechange = function() {
				if (xhttp12.readyState == 4 && xhttp12.status == 200) {
					document.getElementById("city-data").innerHTML = xhttp12.responseText;
			   }
			};
			xhttp12.open("GET", "runajax.php?acn=fetchCityData&sid="+sid, true);
			xhttp12.send();
			*/
			
		})
	});


	function isNumberKey(evt,event)
	{
		var charCode = (evt.which) ? evt.which : evt.keyCode
		if (charCode > 31 && (charCode < 48 || charCode > 57))
			return false;

		return true;
	}	
</script>



<!--------model-------->
<div id="pwdModal" class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" style="display: none;">
	<div class="modal-dialog redem offer_redeem">
		<div class="modal-content">
			<div class="modal-header">

				<button type="button" class="close" data-dismiss="modal" aria-hidden="true" style="opacity: 14; color:#FFF; padding: 1px 17px;">×</button>
				<h2 class="text-center" style="color:#fff;">Redeem Your Point   <small class="label  bg-yellow"><?php echo $totalPoints =  $objProfile->fetchTotalBonus();?></small>

				</h2>

			</div>
			<div class="modal-body">
				<div class="col-md-12">
					<div class="panel panel-default">
						<div class="panel-body">

							<?php
								//$SQL = "SELECT * FROM beatle_products WHERE stock != 0";
								//$rsProducts = $objDB->sql_query($SQL);
							$SQL = "SELECT * FROM beatle_offers  WHERE orgid = ".$_SESSION['OtherInfo']['OrgID']." AND 
							startdate <= '".date('Y-m-d H:i:s')."' AND 
							enddate >= '".date('Y-m-d H:i:s')."' AND 
							active = 'Y' AND
							onhold = 'N'
							ORDER BY startdate DESC";
							$rsOfferData = $objDB->sql_query($SQL);


								//echo "<pre>";
								//print_r($rsProducts);
								//echo "</pre>";


							if(count($rsOfferData) > 0){ 
								
								for($i=0; $i<count($rsOfferData); $i++ ) { 

									$div = $i%4; 

									//if($div == 0) { echo '<div class="text-center Redeem-main">'; }
									?>
									
									<div class="col-md-3">
										<div class="bx-box footer-box offer-data" style="height: 475px; ">
											<div class="box-header ui-sortable-handle bx-box" style="cursor: move;">
												<i class="ion ion-clipboard"></i>
												<h3 class="box-title" style="width:100%;">	<div class="title"> <strong>Title :	&nbsp; </strong><span> <?php echo $rsOfferData[$i]['title'];?></span> </div></h3>
											</div>

											<div class="box-body sub">
												<div class="card-img">
													<div class="card" style="text-align:center;" id="festival-banner"><img style="width:100% !important; height:250px !important;" class="card-bkimg" alt="" src="<?php echo OFFER_BANNER_ROOT.$rsOfferData[$i]['offer_image']?>"></div>
												</div> 
												<div class="card-info" style="text-align: left;">
													<div class="validity"> <strong>Offer Validity : 	&nbsp;</strong> <span> <?php echo date("d/m/Y H:i A",strtotime($rsOfferData[$i]['startdate'])).' to '. date("d/m/Y H:i A",strtotime($rsOfferData[$i]['enddate']));?></span> </div>
													<div class="validity"> <strong>Point require : 	&nbsp;</strong>  <span> <?php echo $rsOfferData[$i]['epoint'];?> </span> </div>

												</div>
												<br>
												<a href="offerprocess.html?prid=<?php echo $rsOfferData[$i]['offerid'];?>" class="btn btn-block btn-primary fancy-btn" style="width: 125px; margin: 0 auto;">Redeem</a>
											</div>
										</div>
									</div>
									<?php  
									//if($div == 3 || $div == count($rsProducts)-1) { echo '</div> <hr>'; }
								}
								
							} else{

								echo 'No any products found';

							} ?>


							
							
							
							
							
							

						</div>
					</div>
				</div>
			</div>
			<div class="modal-footer">
                <!---  <div class="col-md-12">
                    <button class="btn" data-dismiss="modal" aria-hidden="true" style="padding: 8px 30px; margin:0px;
    font-size: 19px;">Cancel</button>
</div>---->
</div>
</div>
</div>
</div>  <!-----offer-redeem------->


<div class="modal fade in" id="modal-default-owner" style="display: none; padding-right: 17px;">
	<div class="modal-dialog own-point Emailer_reddem">
		<div class="modal-content">
			<div class="modal-header">
				<button type="button" class="close" data-dismiss="modal" aria-label="Close">
					<input type="hidden" name="total_redeem_point" id="total_redeem_point" value="<?php echo fetchTotalPointsClient();?>" />
					<span aria-hidden="true">×</span></button>
					<h4 class="modal-title">Redeem Your Point --</h4>
				</div>
				<div class="modal-body">
					<!--<form name="frmRedeem" id="frmRedeem" method="post" action=""> -->
						<div class="owner-redeem-option">
							<div class="tab">
								<button class="tablinks" onclick="openCity(event, 'London')" id="defaultOpen">Emailer</button>
							</div>

							<div id="London" class="tabcontent" >
								<div class="col-md-6">
									<h3>Email</h3>
									<p>1 Bonus Point=1 Credit</p>
									<p>Your Bonus Point <span class="own-point"><?php echo fetchTotalPointsClient();?></span></p>
									<p>Exchange <input class="ent-point" type="number" id="number_val" name="number_val" value=""></p>

									<br>
									<button type="button" class="btn choos-file btn-default" onclick="javascript: redeem_point_client()" style="background: #d29c21; color: #fff; font-size: 17px !IMPORTANT; box-shadow: 1px 1px 3px black;}">Redeem now</button>
								</div>

								<div class="col-md-6">

									<div class="exchange">

										<img src="theme/black/images/mail_exchange.png">		
									</div>					
								</div>


							</div>




						</div>
						<!--</form> -->

					</div>
					<div class="modal-footer"></div>
				</div>

			</div>

		</div>  <!----Emailer_reddem--->



		<div class="modal fade in" id="modal-default-owner12" style="display: none; padding-left: 8px;">
			<div class="modal-dialog own-point email_purchase" style="width: 60%;">
				<div class="modal-content">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal" aria-label="Close">
							<input type="hidden" name="total_redeem_point" id="total_redeem_point" value="230">
							<span aria-hidden="true">×</span></button>
							<h4 class="modal-title">Email Purchase</h4>
						</div>
						<div class="modal-body">
							<!--<form name="frmRedeem" id="frmRedeem" method="post" action=""> -->
								<div class="owner-redeem-option">
									<div class="tab">
										<button class="tablinks active" onclick="openCity(event, 'London')" id="defaultOpen">Emailer</button>
									</div>

									<div id="London" class="tabcontent " style="display: block;">
										<div class="col-md-7">
											<h3>Email Purchase Request</h3>
											<p>1 Email = 4 Paisa</p>
											<p>Email Quantity <input class="ent-point" type="text" id="email_request" name="email_request" value=""></p>     
											<br>
											<button type="button" class="btn choos-file btn-default" onclick="javascript: validatEamilRequest();"  style="background: #d29c21; color: #fff; font-size: 17px !IMPORTANT; box-shadow: 1px 1px 3px black;}">Purchase Email</button>



										</div>
										<div class="col-md-5">
											<div class="price-arrow-left"><img src="theme/black/images/price-arrow.png"></div>
											<!--- <i class="fa fa-arrow-left" aria-hidden="true"></i>-->
											<div class="count-price">
												<h3>your price is</h3>
												<div class="counting-price" id="total-rs">
													<p class="pull-right">00 Email = <span class="pull-right">00</span></p>
													<p class="pull-right">18% Tax = <span class="pull-right">00</span></p>
													<p class="pull-right total-price">Total Rs. = <span class="pull-right">00</span></p>
												</div>
											</div>
										</div>

									</div>




									<!--horizontal-tabbing-script-->

								</div>
								<!--</form> -->

							</div>

						</div>

					</div>

				</div>   <!-----Email Purchase------>


				<div id="pwdModal2" class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" style="display: none;">
					<div class="modal-dialog redem producut_purchase" style="    width: 90%;">
						<div class="modal-content">
							<div class="modal-header">

								<button type="button" class="close" data-dismiss="modal" aria-hidden="true" style="opacity: 14; color:#a5a2a2;font-size:35px; padding: 1px 17px;">×</button>
								<h2 class="text-center" style="color:#fff;">Redeem Your Point  123  <small class="label  bg-yellow"><?php echo $totalPoints =  $objProfile->fetchTotalBonus();?></small>

								</h2>

							</div>
							<div class="modal-body" style="float:left;">
								<div class="col-md-12">
									<div class="panel panel-default">
										<div class="panel-body">

											<?php
											$SQL = "SELECT * FROM beatle_products WHERE stock != 0";
											$rsProducts = $objDB->sql_query($SQL);

								//echo "<pre>";
								//print_r($rsProducts);
								//echo "</pre>";


											if(count($rsProducts) > 0){ 

												for($i=0; $i<count($rsProducts); $i++ ) { 

													$div = $i%4; 

									//if($div == 0) { echo '<div class="text-center Redeem-main">'; }
													?>


													<div class="col-md-3 Redeem-box">
														<div class="Redeem-item">

															<?php
															if($_SERVER['HTTP_HOST']=='localhost' || $_SERVER['HTTP_HOST']=='kalpeshpc' ) { 
																echo '<img src="http://'.$_SERVER['HTTP_HOST'].'/newdemo.beatleanalytics.com/assets/products/'.$rsProducts[$i]['prod_image'].'">';
															}else{
																if(SUBDOMAIN_NAME == 'owner'){ 
																	echo '<img src="http://newdemo.beatleanalytics.com/assets/products/'.$rsProducts[$i]['prod_image'].'">';
																}else if(SUBDOMAIN_NAME == 'manage'){
																	echo '<img src="http://manage.beatleanalytics.com/assets/products/'.$rsProducts[$i]['prod_image'].'">';
																}
															} 
															?>


														</div>
														<div class="point-rd">
															<p style="margin:0;">BeatleBuddy</p>
															<b><?php echo $rsProducts[$i]['name'];?></b>
															<p><?php echo $rsProducts[$i]['points'];?><span> Point</span></p>

															<div class="col-md-3"></div>
															<div class="col-md-6 prodacat-btn">
																<?php
																if($totalPoints >= $rsProducts[$i]['points']) {
																	?>
																	<a href="orderprocess.html?prid=<?php echo $rsProducts[$i]['productid'];?>" class="btn btn-block btn-primary">Redeem Now</a>
																<?php } else {   ?>
																	<a onclick="javascript:;" href="#" class="btn btn-block btn-primary disabled">Redeem Now</a>
																<?php  }?>

															</div>
															<div class="col-md-3"></div>  

														</div>
													</div>



													<?php  
									//if($div == 3 || $div == count($rsProducts)-1) { echo '</div> <hr>'; }
												}

											} else{

												echo 'No any products found';

											} ?>









										</div>
									</div>
								</div>
							</div>

						</div>
					</div>
				</div>   <!---producut_purchase--->

				<!--------model------->












				<!-------bonuss-point-round-start---->
				<style>

				.heads {
					background:url(theme/black/images/redeem-round.png); background-repeat:no-repeat;
					z-index: 2;
					transform: rotateY(0deg);
				}
				.tails {
					background:url(theme/black/images/tails.png); background-repeat:no-repeat;
					z-index: 1;
					transform: rotateY(180deg);
				}

				.bonus-point {
					background:url(theme/black/images/development.png); background-repeat:no-repeat; height: 261px;     height: 261px;
					margin: 0 auto;
					text-align: center;
					width: 178px;
				}


			</style>


			<!--------last profile page 16-4-2018---------------->

			<style>
			.profile_corpo .profile-user-img {
				border: 3px solid #ffffff;
				background: #868686;
			}

			.profile_corpo .profile_pic span.text-content1 {left: 3px;top: 8px;}


			.profile_corpo .profile_pic .span.text-content1 span {
				opacity: 1;
				width: 130px;
				height: 130px;
			}
			.profile_corpo .profile_pic span.text-content1 {

				height: 130px;

				width: 130px;

			}
			body.sidebar-mini.skin-blue.pace-done.sidebar-collapse  .profile_corpo span.text-content1 {display:inline-table;}

			.profile_corpo .profile_pic ul.img-list1 li:hover span.text-content1 {
				opacity: 1 !IMPORTANT;
				width: 130px !IMPORTANT;
				height: 130px !IMPORTANT;
			}
			.profile_corpo .profile_pic ul.img-list1 li {
				display: inline-block;
				height: 138px !IMPORTANT;
				position: relative !IMPORTANT;
				width: 138px !IMPORTANT;
			}
			.profile_corpo h5 {
				text-align: center;
				position: absolute;
				top: 96px;
				width: 100%;
				font-size: 19px;
				color: #fff;
				margin-top: 15px;
			}
			.mrq.purch span {
				margin-left: 13px;
			}
			.mrq span {
				margin-left: 85px;
			}
			.mrq p {
				font-size: 18px;
				margin-bottom: 11px !IMPORTANT;
				border-bottom: 1px solid #ddd;
			}
			.mrq {
				width: 90%;
				margin: 0 auto;
			}
			.profile_corpo {
				width: 100%;
				background: #45c3d1;
				height:162px;
				margin-top: 79px;
				position: relative;
				border-radius: 3px;
			}
			.profile_corpo .profile-user-img {
				margin: 0 auto;
				width: 154px;
				padding: 3px;
				border: 3px solid #d2d6de;
			}
			.profile_corpo .profile_pic {
				position: absolute;
				top: -75px;
				width: 100%;
				text-align: center;
			}

			.profile_corpo h2{
				text-align: center;
				position: absolute;
				top: 76px;
				margin: 0 auto;
				color: #ffff;
				width: 100%;
			}
			.profile_corpo .profile-user-img {

				border: 3px solid #ffffff;
			}
			.profile_corpo .edit_btn a {
				background: #fff !IMPORTANT;
				color: black !IMPORTANT;
				border:2px solid #2473a2;
				border-radius: 17px;
				font-size: 17px;
				padding: 8px 43px;
			}
			.profile_corpo .edit_btn {
				text-align: center;
				position: absolute;
				width: 100%;
				bottom: -23px;
			}
			.box.box-widget.widget-user.pro_pic {
				border: 1px solid #00a7d0;
			}

			.what_we_provide_info.beatle_point h1 {
				color: #f6821f !IMPORTANT;
				font-weight: 900;
			}

			.what_we_provide_info.beatle_point h2 {
				color: #f6821f !IMPORTANT;

			}

			.what_we_provide_info.beatle_email h2 {
				color: #89c742;
			}
			.what_we_provide_info.beatle_email h1 {
				color: #89c742; font-weight: 900;
			}
			.what_we_provide_info.beatle_sms h2 {
				color: #45c3d1;
			}
			.what_we_provide_info.beatle_sms h1 {
				color: #45c3d1;font-weight: 900;
			}

			.box-body.per-info p {
				margin: 6px 0;
				color: #484848;
				font-size: 17px;
			}


			.box.box-warning.box-solid {
				border: 1px solid #253035;
				border-radius: 3px;
			}
			.what_we_provide_info h1 , .what_we_provide_info h2 {
				text-align: center;
				margin: 0px;
				padding: 5px 0;
				font-family: 'Rajdhani', sans-serif;
				line-height: normal;
				font-size: 30px;
				color: #666666;
				text-transform: uppercase;
			}

			.clear_b{clear: both;}
			.what_we_provide_icon a {

				float: none;
				margin: 0px auto;
				display: table;    position: relative !IMPORTANT;    width: 165px;
			}
			.what_we_provide_icon 

			{ position: relative;  float: left;  width: 100%;

			}
			.what_we_provide span:nth-child(1) 

			{ border: 2px solid red; border-radius: 100px; height: 122px; left: 70px; position: absolute;  top: -11px;  width: 122px;  transition: all 0.5s ease-in-out 0s; -webkit-transition: all 0.5s ease-in-out 0s;  border-top: 2px solid transparent; transform: rotate(134deg) ; -webkit-transform: rotate(134deg);

			}
			.what_we_provide:hover span:nth-child(1) 

			{transition: all 0.5s ease-in-out 0s; -webkit-transition: all 0.5s ease-in-out 0s;  border-top: 2px solid transparent; transform: rotate(800deg);

				-webkit-transform: rotate(800deg);}

				.what_we_provide span:nth-child(2)

				{width:122px; height:122px; transition: all 0.5s ease-in-out 0s; -webkit-transition: all 0.5s ease-in-out 0s; display:block; z-index:1; transform: rotate(134deg); -webkit-transform: rotate(134deg);

				}
				.circle 

				{ background:red; width:145px; height:145px; text-align:center; display:table; vertical-align:middle; border-radius:100px; color:#fff; font-size:50px;

					position:absolute; left:7%; top:0px  

				}
				.circle .fa 

				{ display: table-cell; vertical-align: middle;

				}
				.custom_design span:nth-child(1) 

				{ border:2px #f6821f solid;  border-top: 2px solid transparent;

				}
				.custom_design.circle 

				{ background-color: #f6821f;

				} 
				.custom_code.circle

				{ background-color: #89c742;

				} 
				.custom_code span:nth-child(1) 

				{ border:2px #89c742 solid;  border-top: 2px solid transparent;

				}
				.inventory.circle

				{ background-color: #45c3d1;

				}

				.inventory	 span:nth-child(1) 

				{ border:2px #45c3d1 solid;  border-top: 2px solid transparent;

				}

				.amazon_ebay.circle

				{ background-color: #eb008d;

				}

				.amazon_ebay span:nth-child(1) 

				{ border:2px #eb008d solid;  border-top: 2px solid transparent;

				}

				.what_we_provide span:nth-child(1) {
					height: 165px !IMPORTANT;
					left:0px !IMPORTANT;
					position: absolute !IMPORTANT;
					top: -11px !IMPORTANT;
					width: 165px !IMPORTANT;
				}
				.proces_step img {width:550px; margin:0 auto;}
				.proces_step {text-align:center;}
				.what_we_provide_info {
					CLEAR: BOTH;
					FLOAT: LEFT;
					WIDTH: 100%;
					TEXT-ALIGN: CENTER;
					MARGIN-TOP: 34px;
				}
				.pr_hed {
					background: #484848 !IMPORTANT;
				}
			</style>


			<style>
			.modal-header small.label.bg-yellow {
				font-size: 30px;
				border-radius: 11px;
			}



			.edit-profile button {
				font-size: 22px;
				padding: 11px 30px;
				background: #e08e0b;
			}

			.edit-profile {margin-top:25px;}
			.box-header.with-border {
				background: #394247;
			}
			.profile-box {
				margin-top: 17px;
			}
			.box-body.map {
				background: whitesmoke;
			}

			.box-header.with-border.box-header { border-radius:4px;}



			.modal-content .modal-header .my-point{    width: 75px;
				height: 75px;
				float: left;}


				.modal-content .modal-header .my-point P{ padding: 21px 0;
					TEXT-ALIGN: CENTER;
					font-size: 25px;}

					.popover.fade.right.in h3.popover-title {
						color: black !IMPORTANT;
						font-size: 19px !IMPORTANT;
						box-shadow: 0 0 black !important;
					}
					.popover.fade.right.in{
						WIDTH: 193PX;}
						.count-price {
							text-align: center;
							height: 200px;
							border: 1px solid #ddd;
							margin-top: 38px;
						}
						.counting-price {
							/* clear: both; */
							width: 74%;
							margin: 0 auto;
							display: flow-root;
							text-align: center;
						}
						.counting-price p {

							font-size: 17px !IMPORTANT;
							width: 250px; text-align:right;
						}
						.total-price {
							border-top:1px solid #ddd;
						}
						.card-info .validity , .card-info .descri {
							font-size: 14px;
							margin-bottom: 4px;    clear: both;

						}
						.modal-dialog {
							width: 80%;
							margin: 30px auto;
						}
						.modal-body {

							background: #FFF;
						}
						.box-header.with-border.pr_hed {    BORDER-RADIUS: 0PX 0PX 0PX 0PX;}
					</style>
					<!------//--last profile page 16-4-2018---------------->