        	<div id="headerProfile">

				<?php if (!empty($D->u->cover)) { ?>

               	
                <div id="coverProfile" style="background-position: center; background-image: url(<?php echo $C->SITE_URL.$C->FOLDER_COVERS?>min1/<?php echo $D->u->cover?>);">
                	<div>
	                    <a href="<?php echo $C->SITE_URL.$C->FOLDER_COVERS.$D->u->cover?>" id="coverProfilePhoto"><div class="coverBorder"></div></a>
                    </div>
                    <div class="nameProfile">
                    
                    	<?php if ($D->he_follows_me) { ?><div style="line-height:20px;"><span class="hefollows"><?php echo $this->lang('profile_infobasic_followsyou'); ?></span></div><?php } ?>
                        
                        <div>

                            <a href="<?php echo $C->SITE_URL.$D->u->username?>" class="undecorated"><div id="txtnameprofile">
                            
                            	<span><?php echo $D->nameUser ?></span> 
                            
								<?php if ($D->isUserVerified == 1) { ?>
                                <span>
                                    <span style="position:relative; margin-left:5px; vertical-align:-5px;">
                                        <img src="<?php echo $C->SITE_URL?>themes/<?php echo $C->THEME ?>/imgs/userverified.png" title="<?php echo $this->lang('profile_infobasic_title_verified')?>">
                                    </span>
                                </span>
                                <?php } ?>
                            
                            </div></a>
                            <div class="sh"></div>
                        
                        </div>

                    </div>
                </div>
                

				<?php } else { ?>

                <div id="withoutCover">
                
                	<div class="nameProfile nameWithoutCover">
                    
                    	<?php if ($D->he_follows_me) { ?><div style="line-height:20px;"><span class="hefollows"><?php echo $this->lang('profile_infobasic_followsyou'); ?></span></div><?php } ?>
                        
                        <div>

                            <a href="<?php echo $C->SITE_URL.$D->u->username?>" class="undecorated"><div id="txtnameprofile">
                            
                            	<span><?php echo $D->nameUser ?></span> 
                            
								<?php if ($D->isUserVerified == 1) { ?>
                                <span>
                                    <span style="position:relative; margin-left:5px; vertical-align:-5px;">
                                        <img src="<?php echo $C->SITE_URL?>themes/<?php echo $C->THEME ?>/imgs/userverified.png" title="<?php echo $this->lang('profile_infobasic_title_verified')?>">
                                    </span>
                                </span>
                                <?php } ?>
                            
                            </div></a>
                            <div class="sh"></div>

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

                <?php } ?>
                
                <div id="infoProfile">
                	<div class="infoBar">
                        <div class="opcsBar">
                        	<a href="<?php echo $C->SITE_URL.$D->u->username?>" class="opcOne undecorated">
                            <div id="numposts" class="basic-number"><?php echo $D->u->num_posts_inwall; ?></div>
                            <div class="txtminitop basic-text"><?php echo ($D->u->num_posts_inwall==1?$this->lang('profile_infobasic_post'):$this->lang('profile_infobasic_posts'))?></div>
                            <div class="icominitop"><img src="<?php echo $C->SITE_URL?>themes/<?php echo $C->THEME ?>/imgs/icomenuactivity20.png" title="<?php echo ($D->u->num_posts==1?$this->lang('profile_infobasic_post'):$this->lang('profile_infobasic_posts'))?>"></div>
                            </a>
                            <a href="<?php echo $C->SITE_URL.$D->u->username?>/friends" class="opcOne undecorated">
                            <div id="numfriends" class="basic-number"><?php echo $D->u->num_friends; ?></div>
                            <div class="txtminitop basic-text"><?php echo ($D->u->num_friends==1?$this->lang('profile_infobasic_friend'):$this->lang('profile_infobasic_friends'))?></div>
                            <div class="icominitop"><img src="<?php echo $C->SITE_URL?>themes/<?php echo $C->THEME ?>/imgs/icodashboardfollowing.png" title="<?php echo ($D->u->num_friends==1?$this->lang('profile_infobasic_friend'):$this->lang('profile_infobasic_friends'))?>"></div>
                            </a>

                            <span class="opcOneb undecorated">
                            <?php $this->load_template('__bfriend.php'); ?>
                            </span>
                            
                            <?php if ($D->friendship == 1) { ?>
                            <span id="spaceFollow" class="opcOnec undecorated">
                            <?php $this->load_template('__bfollow.php'); ?>
                            </span>
                            <?php } ?>
                        	<div class="sh"></div>
                        </div>
	                	<div class="sh"></div>
                    </div>
                    <div id="avatarProfile">
                    	<?php if (empty($D->u->avatar)) {?>

                    	<span class="thumbPhoto thumbWithoutCover"><img src="<?php echo $C->SITE_URL.$C->FOLDER_AVATAR?>min4/default.jpg" class="imgPhoto imgWithoutCover"></span>

                        <?php } else { ?>

                    	<a id="avatarProfilePhoto" href="<?php echo $C->SITE_URL.$C->FOLDER_AVATAR.'origins/'.$D->u->avatar?>" class="thumbPhoto thumbWithoutCover"><img src="<?php echo $C->SITE_URL.$C->FOLDER_AVATAR?>min4/<?php echo $D->u->avatar?>" class="imgPhoto imgWithoutCover"></a>
                        
                        <?php } ?>
                    </div>
                </div>

            </div>
<script>    
	$("#avatarProfilePhoto").magnificPopup({
		type: 'image',
		closeOnContentClick: true,
		mainClass: 'mfp-img-mobile',
		image: {
		verticalFit: true
		}
	});
	
	$("#coverProfilePhoto").magnificPopup({
		type: 'image',
		closeOnContentClick: true,
		mainClass: 'mfp-img-mobile',
		image: {
		verticalFit: true
		}
	});
</script>
