<div>
    <ul class="breadcrumb">
        <li>
            <a href="index.php">Home</a>
        </li>
      
        <li>
            <a href="index.php?page=vol_profile&PID=<?php echo  ($_REQUEST['PID']); ?>&aid=<?php echo($_REQUEST['aid']);  ?>"> view profile</a>
        </li>
    </ul>
</div>






<div class="row">
        <div class="box col-md-12">
            <div class="box-inner">
                <div class="box-header well" data-original-title="">
                    <h2><i class="glyphicon glyphicon-th"></i> Volunteer profile</h2>

                    <div class="box-icon">
                        <a href="#" class="btn btn-setting btn-round btn-default"><i
                                class="glyphicon glyphicon-cog"></i></a>
                        <a href="#" class="btn btn-minimize btn-round btn-default"><i
                                class="glyphicon glyphicon-chevron-up"></i></a>
                        <a href="#" class="btn btn-close btn-round btn-default"><i
                                class="glyphicon glyphicon-remove"></i></a>
                    </div>
                </div>
                <div class="box-content">
                    
                    
                     <?php 
$query="select * from personal_info
 inner join blod on blod_id=personal_info_blodId 
 inner join country on country_id=personal_info_countryid
 inner join city on city_id=personal_info_cityId
 inner join driving_type on driving_Type_id=personal_info_driving_typeid
 inner join gender on gender_id=personal_info_genderid
 inner join citizenship on citizenship_id=personal_info_citizenship
 where personal_info_id=".$_REQUEST['PID'];
$result=mysqli_query($conn,$query);

if($result)
    {
	$row=mysqli_fetch_assoc($result);
	}

//////to show work
$work_q="select * from personal_work
inner join country on country_id=personal_work_countryid
where personal_work_personalid=".$_REQUEST['PID'];
$work_result=mysqli_query($conn,$work_q);
//echo ($work_q);
if($work_result)
    {
	$work_row=mysqli_fetch_assoc($work_result);
	}
	
	/////////to shoow dissease
	
	$dissease_q="select * ,group_concat(disease_name_en)disease from personal_disease
inner join disease on disease_id=personal_disease_diseaseid
where personal_disease_personalid=".$_REQUEST['PID'];
	$diseas_result=mysqli_query($conn,$dissease_q);
if($result)
    {
	$diseas_row=mysqli_fetch_assoc($diseas_result);
	}
?>
                    
                    
                  
                    
                    
                    
                    
                    <!------- firs collapse  ----->
                    <a href="#personal_info" data-toggle="collapse" data-target="#personal_info"  ><i class="glyphicon glyphicon-plus"></i>Personal information</a>

   <div id="personal_info" class="collapse ">
                    
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="20%"><img   width="150" height="150" src="upload/<?php  echo($row['personal_info_imgpersonal']);  ?>" /></td>
        <td width="80%" valign="top"><table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
          <tr>
            <td width="15%" height="35" align="left"><strong><?php echo lang("personal_name",$conn);  ?> </strong></td>
            <td width="34%" align="left"><?php echo($row['personal_info_name']); ?></td>
            <td width="16%" align="left"><strong><?php echo lang("personal_DOB",$conn);  ?></strong></td>
            <td width="35%" align="left"><?php echo($row['personal_info_DOB']); ?></td>
          </tr>
          <tr>
            <td height="35" align="left"><strong><?php echo lang("personal_gender",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['gender_name_en']); ?></td>
            <td align="left"><strong><?php echo lang("martial_Status",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['personal_info_martialStatus']); ?></td>
          </tr>
          <tr>
            <td height="35" align="left"><strong><?php echo lang("personal_citizenship",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['citizenship_name_'.$_SESSION['langCode']]); ?> </td>
            <td align="left"><strong><?php echo lang("personal_ID",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['personal_info_identity']); ?></td>
          </tr>
          <tr>
            <td height="35" align="left"><strong><?php echo lang("personal_pass_num",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['personal_info_passID']); ?></td>
            <td align="left"><strong><?php echo lang("personal_pass_date",$conn);  ?></strong></td>
            <td align="left"><?php echo($row['personal_info_pssExpireDate']); ?></td>
          </tr>
          
        </table>
        
        </td>
      </tr>
    </table>
    
    <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="15%" height="35" align="left"><strong><?php  echo(lang("country",$conn)); ?></strong></td>
        <td width="26%" align="left"><?php echo($row['country_name_en']); ?></td>
        <td width="18%" align="left"><strong><?php echo lang("personal_city",$conn);  ?></strong></td>
        <td width="41%" align="left"><?php echo($row['city_name_'.$_SESSION['langCode']]); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_town",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_twon']); ?></td>
        <td align="left"><strong><?php echo lang("personal_street",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_street']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_blod",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['blod_type']); ?></td>
        <td align="left"><strong><?php echo lang("personal_glass",$conn);  ?></strong></td>
        <td align="left"><?php if($row['personal_info_hasGlass']==1){echo("yes");}else echo("No"); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_have_licence",$conn);  ?></strong></td>
        <td align="left"><?php if($row['personal_info_hasDriving']==1){echo("yes");}else echo("No"); ?></td>
        <td align="left"><strong><?php echo lang("personal_type_licence",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['driving_Type_name_'.$_SESSION['langCode']]); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_has_health",$conn);  ?></strong></td>
        <td align="left"><?php if($row['personal_info_hasHelthpro']==1){echo("yes");}else echo("No"); ?></td>
        <td align="left"><strong><?php echo lang("personal_type_of_dissease",$conn);  ?></strong></td>
        <td align="left"><?php echo($diseas_row['disease']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_facebook",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_facebook']); ?></td>
        <td align="left"><strong><?php echo lang("personal_instagram",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_instagram']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_twitter",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_tweeter']); ?></td>
        <td align="left"><strong><?php echo lang("personal_has_work",$conn);  ?></strong></td>
        <td align="left"><?php if($row['personal_info_hasWork']==1){echo("yes");}else echo("No"); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_work_title",$conn);  ?></strong></td>
        <td align="left"><?php echo($work_row['personal_work_jobTitle']); ?></td>
        <td align="left"><strong><?php echo lang("personal_work_comp",$conn);  ?></strong></td>
        <td align="left"><?php echo($work_row['personal_work_org']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php echo lang("personal_work_country",$conn);  ?></strong></td>
        <td align="left"><?php echo($work_row['country_name_'.$_SESSION['langCode']]); ?></td>
        <td align="left"><strong><?php echo lang("personal_zip",$conn);  ?></strong></td>
        <td align="left"><?php echo($row['personal_info_ZIP']); ?></td>
      </tr>
    </table>
    
       
</div>
                    
       <!------- end of firs collapse  ----->    
       
       <br>
        <!------- start of 2ndcollapse  ----->    
        
        
        <a href="#contact_info" data-toggle="collapse" data-target="#contact_info"  ><i class="glyphicon glyphicon-plus"></i>Contact information</a>
        <div id="contact_info" class="collapse">
        
        <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="15%" height="35" align="left"><strong><?php  echo(lang("home_tel",$conn)); ?></strong></td>
        <td width="34%" align="left"><?php echo($row['personal_info_homeTel']); ?></td>
        <td width="16%" align="left"><strong><?php  echo(lang("work_tel",$conn)); ?></strong></td>
        <td width="35%" align="left"><?php echo($row['personal_info_workTel']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php  echo(lang("mobile",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_mobile']); ?></td>
        <td align="left"><strong><?php  echo(lang("fax",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_fax']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php  echo(lang("Email",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_email']); ?></td>
        <td align="left"><strong><?php  echo(lang("po_box",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_POBOX']); ?></td>
      </tr>
    </table>
        
        
        
    
        
        </div>
        
        

        
         <!------- end of 2nd collapse  -----> 
         
         
         <br>
             
           <!------- start of 3rd collapse  ----->
           
           
            
          <a href="#emergency_cont" data-toggle="collapse" data-target="#emergency_cont"  ><i class="glyphicon glyphicon-plus"></i>Emergency Contact</a>          
             <div  id="emergency_cont" class="collapse">
             <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="15%" height="35" align="left"><strong><?php  echo(lang("emerg_name",$conn)); ?></strong></td>
        <td width="34%" align="left"><?php echo($row['personal_info_emergNmae']); ?></td>
        <td width="16%" align="left"><strong><?php  echo(lang("emerg_mob",$conn)); ?></strong></td>
        <td width="35%" align="left"><?php echo($row['personal_info_emergMobile']); ?></td>
      </tr>
      <tr>
        <td height="35" align="left"><strong><?php  echo(lang("emerg_email",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_emergeEmail']); ?></td>
        <td align="left"><strong><?php  echo(lang("emerg_address",$conn)); ?></strong></td>
        <td align="left"><?php echo($row['personal_info_emergAddress']); ?></td>
      </tr>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 3rd collapse  -----> 
                    <br>

                    
            <!------- start of 4th collapse  ----->
           
           
            
          <a href="#education" data-toggle="collapse" data-target="#education"  ><i class="glyphicon glyphicon-plus"></i>Education</a>          
             <div  id="education" class="collapse">
             <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="11%" height="35" align="left"><strong><?php  echo(lang("degree",$conn)); ?></strong></td>
        <td width="15%" align="left"><strong><?php  echo(lang("specialist",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("organization",$conn)); ?></strong></td>
        <td width="28%" align="left"><strong><?php  echo(lang("country",$conn)); ?></strong></td>
        <td width="28%" align="left"><strong><?php  echo(lang("year",$conn)); ?></strong></td>
        </tr>
        <?php 
		$edu_q="select * from education
inner join degree on degree_id=education_degreeId
inner join country on country_id=education_cityId
where education_personalId=".$_REQUEST['PID'];
		$edu_result=mysqli_query($conn,$edu_q);
//echo ($edu_q);
if($edu_result)
    {
	while($edu_row=mysqli_fetch_assoc($edu_result))
	{
		?>
		
      <tr>
        <td height="35" align="left"><?php echo($edu_row['degree_name_'.$_SESSION['langCode']]); ?></td>
        <td align="left"><?php echo($edu_row['education_specialist']); ?></td>
        <td align="left"><?php echo($edu_row['education_university']); ?></td>
        <td align="left"><?php echo($edu_row['country_name_'.$_SESSION['langCode']]); ?></td>
        <td align="left"><?php echo($edu_row['education_graduationYear']); ?></td>
        </tr>
        <?php
	}
	}
		 ?>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 4th collapse  -----> 
                             
                    <br>

                    
              <!------- start of 5th collapse  ----->
           
           
            
          <a href="#courses" data-toggle="collapse" data-target="#courses"  ><i class="glyphicon glyphicon-plus"></i>Courses</a>          
             <div  id="courses" class="collapse">
             <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="11%" height="35" align="left"><strong><?php  echo(lang("courses_name",$conn)); ?></strong></td>
        <td width="15%" align="left"><strong><?php  echo(lang("yaer",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("country",$conn)); ?></strong></td>
        </tr>
        
          <?php 
		$course_q="select * from courses
inner join country on country_id=courses_cityid
where courses_personalid=".$_REQUEST['PID'];
		$course_result=mysqli_query($conn,$course_q);
//echo ($edu_q);
if($course_result)
    {
	while($course_row=mysqli_fetch_assoc($course_result))
	{
		?>
        
      <tr>
        <td height="35" align="left"><?php echo($course_row['courses_name']); ?></td>
        <td align="left"><?php echo($course_row['courses_year']); ?></td>
        <td align="left"><?php echo($course_row['country_name_'.$_SESSION['langCode']]); ?></td>
        </tr>
        
        <?php }}?>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 5th collapse  ----->         
                    
                    
                   <br>
 <!------- start of 6th collapse  ----->
           
           
            
          <a href="#experience" data-toggle="collapse" data-target="#experience"  ><i class="glyphicon glyphicon-plus"></i>Previous voluntary</a>          
             <div  id="experience" class="collapse">
             <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="11%" height="35" align="left"><strong><?php  echo(lang("vol_field",$conn)); ?></strong></td>
        <td width="15%" align="left"><strong><?php  echo(lang("organization",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("from",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("to",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("country",$conn)); ?></strong></td>
      </tr>
      <?php 
		$vol_q="select * from experience
inner join country on country_id=experience_cityId
where experience_personalId=".$_REQUEST['PID'];
		$vol_result=mysqli_query($conn,$vol_q);
//echo ($edu_q);
if($vol_result)
    {
	while($vol_row=mysqli_fetch_assoc($vol_result))
	{
		?>
      
      <tr>
        <td height="35" align="left"><?php echo($vol_row['experience_field']); ?></td>
        <td align="left"><?php echo($vol_row['experience_org']); ?></td>
        <td align="left"><?php echo($vol_row['experience_from']); ?></td>
        <td align="left"><?php echo($vol_row['experience_to']); ?></td>
        <td align="left"><?php echo($vol_row['country_name_'.$_SESSION['langCode']]); ?></td>
      </tr>
      <?php  }}?>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 6th collapse  ----->         
                     
                    
                    
                               
                   <br>
 <!------- start of 7th collapse  ----->
           
           
            
          <a href="#languages" data-toggle="collapse" data-target="#languages"  ><i class="glyphicon glyphicon-plus"></i>Languages</a>          
             <div  id="languages" class="collapse">
             
             <table width="100%" border="1" cellspacing="2" cellpadding="5" style="border: 1px  #FFF"  class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="11%" height="35" align="left"><strong><?php  echo(lang("Lnguage_name",$conn)); ?></strong></td>
        <td width="15%" align="left"> <strong><?php  echo(lang("speak",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("read",$conn)); ?></strong></td>
        <td width="18%" align="left"><strong><?php  echo(lang("write",$conn)); ?></strong></td>
        </tr>
        <?php 
		
		 $lang_q="select *

,(select languages_skill_name_".$_SESSION['langCode']." from languages_skill 
where languages_skill_id=personal_languages_readId
) readName
,(select languages_skill_name_".$_SESSION['langCode']." from languages_skill 
where languages_skill_id=personal_languages_writeId
) writeName
,(select languages_skill_name_".$_SESSION['langCode']." from languages_skill 
where languages_skill_id=personal_languages_speakId
) speackName


 from personal_languages
inner join languages on languages_id=personal_languages_languagesId
and personal_languages_personalinfoid=".$_REQUEST['PID']; 
		$lang_result=mysqli_query($conn,$lang_q);
//echo ($edu_q);
if($lang_result)
    {
	while($lang_row=mysqli_fetch_assoc($lang_result))
	{
		?>
		
        
      <tr>
        <td height="35" align="left"><?php echo($lang_row['languages_name_'.$_SESSION['langCode']]); ?></td>
        <td align="left"><?php echo($lang_row['speackName']); ?></td>
        <td align="left"><?php echo($lang_row['readName']); ?></td>
        <td align="left"><?php echo($lang_row['writeName']); ?></td>
        </tr>
        <?PHP  }}?>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 7th collapse  ----->       
                    
                        <br>
 <!------- start of 8th collapse  ----->
           
           
            
          <a href="#skill" data-toggle="collapse" data-target="#skill"  ><i class="glyphicon glyphicon-plus"></i>Skills</a>          
             <div  id="skill" class="collapse">
             
             <table width="100%" border="0" cellspacing="3" cellpadding="3" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="20%" align="left" valign="top"><h4><?php  echo(lang("skills",$conn)); ?></h4></td>
        <td width="80%" align="left" valign="bottom">
          <?php  
	$skill_q="select * from personal_skills
inner join skills on skills_id=personal_skills_skillsid
where personal_skills_personalinfoid=".$_REQUEST['PID'];
	$skill_result=mysqli_query($conn,$skill_q);
//echo ($edu_q);
if($skill_result)
    {
	while($skill_row=mysqli_fetch_assoc($skill_result))
	{
	?>
          <span><?php echo($skill_row['skills_name_'.$_SESSION['langCode']]);  ?></span>
          <?php }}
	 ?></td>
      </tr>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 8th collapse  ----->  
                    
                        <br>
 <!------- start of 9th collapse  ----->
           
           
            
          <a href="#activity" data-toggle="collapse" data-target="#activity"  ><i class="glyphicon glyphicon-plus"></i>Interested Activity</a>          
             <div  id="activity" class="collapse">
             
             <table width="100%" border="0" cellspacing="3" cellpadding="3"class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="20%" align="left" valign="top"><h4><?php  echo(lang("interested_activity",$conn)); ?></h4></td>
        <td width="80%" align="left" valign="bottom"><?php 
    $activity_q="select * from personal_inerested_activity
inner join interested_activity on interested_activity_id=p_i_a_interstedActivityId
where p_i_a_personalinfoid=".$_REQUEST['PID'];
	$activity_result=mysqli_query($conn,$activity_q);
//echo ($edu_q);
if($activity_result)
    {
	while($activity_row=mysqli_fetch_assoc($activity_result))
	{
	?>
          <span><?php echo($activity_row['interested_activity_name_'.$_SESSION['langCode']]);  ?></span>
          <?php }}
	 ?></td>
      </tr>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 9th collapse  ----->                  
                    
                    
                    
                    
           <br>
 <!------- start of 10th collapse  ----->
           
           
            
          <a href="#group" data-toggle="collapse" data-target="#group"  ><i class="glyphicon glyphicon-plus"></i>Target group</a>          
             <div  id="group" class="collapse">
             
             <table width="100%" border="0" cellspacing="3" cellpadding="3" class="table table-striped table-bordered bootstrap-datatable datatable responsive">
      <tr>
        <td width="20%" align="left" valign="top"><h4><?php  echo(lang("Target_Group",$conn)); ?></h4></td>
        <td width="80%" align="left" valign="bottom"><?php 
    $target_q="select * from personal_group
inner join target_group on target_group_id=personal_group_targetgroupid
where personal_group_personalid=".$_REQUEST['PID'];
	$target_result=mysqli_query($conn,$target_q);
//echo ($edu_q);
if($target_result)
    {
	while($target_row=mysqli_fetch_assoc($target_result))
	{
	?>
          <span><?php echo($target_row['target_group_name_'.$_SESSION['langCode']]);  ?></span>
          <?php }}
	 ?></td>
      </tr>
    </table>
             
         </div>    
             
             
                    
           <!------- end of 10th collapse  ----->                  
                    <br>
<br>
<br>
                    
                    
                </div>
            </div>
        </div>
        <!--/span-->
    </div>