HEX
Server: nginx/1.24.0
System: Linux DGT-WORDPRESS-VM-SERVER 6.14.0-1014-azure #14~24.04.1-Ubuntu SMP Fri Oct 3 20:52:11 UTC 2025 x86_64
User: ubuntu (1000)
PHP: 8.4.12
Disabled: NONE
Upload Files
File: /mnt/data/doccure-wp/wp-content/themes/doccure/template-parts/header/layouts/layout-1.php
<?php
/**
 * Template part for header layout 10
 *
 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
 *
 * @package doccure
 */
  $top_header_width_class = (doccure_get_option('adjust-custom-header-top-width') == true && doccure_get_option('header-top-width-style') == 'full-width') ? 'container-fluid' : 'container';
 
 global $doccure_options;
$is_register	= !empty( $doccure_options['registration_form'] ) ? $doccure_options['registration_form'] : '';
 $is_login		= !empty( $doccure_options['login_form'] ) ? $doccure_options['login_form'] : '';
 $user_registration		= !empty( $doccure_options['user_registration'] ) ? $doccure_options['user_registration'] : '';


 $page_id = get_the_ID();
 $post_meta			= doccure_get_post_meta( $page_id );
 if( !empty( $post_meta['am_header_style'] ))
 { 
   $header_class =   $post_meta['am_header_style'];
 }  else {
   $header_class = "";
 }

 // Mobile Header
  ?> 
 <div class="header-topbar">
				<div class="container">
					<div class="topbar-info">
 						<div class="d-flex align-items-center gap-3 header-info">
							<p><i class="isax isax-message-text5 me-1"></i><?php echo doccure_get_option('header_top_email'); ?></p>
							<p><i class="isax isax-call5 me-1"></i><?php echo doccure_get_option('header_top_phone'); ?></p>
						</div>
						<ul class="mb-0 ps-0">
							 
 							<li class="social-header">
								<div class="social-icon">
   <?php if(doccure_get_option('header_social_facebook')) { ?> 
									<a href="<?php echo doccure_get_option('header_social_facebook'); ?>" target="_blank"><i class="fa-brands fa-facebook"></i></a>
                  <?php } ?>
                  <?php if(doccure_get_option('header_social_twitter')) { ?> 
									<a href="<?php echo doccure_get_option('header_social_twitter'); ?>" target="_blank"><i class="fa-brands fa-x-twitter"></i></a>
                  <?php } ?>
                  <?php if(doccure_get_option('header_social_instagram')) { ?> 
									<a href="<?php echo doccure_get_option('header_social_instagram'); ?>" target="_blank"><i class="fa-brands fa-instagram"></i></a>
                  <?php } ?>
                  <?php if(doccure_get_option('header_social_pinterest')) { ?> 
									<a href="<?php echo doccure_get_option('header_social_pinterest'); ?>" target="_blank"><i class="fa-brands fa-linkedin"></i></a>
                  <?php } ?>
                  <?php if(doccure_get_option('header_social_linkedin')) { ?> 
									<a href="<?php echo doccure_get_option('header_social_linkedin'); ?>" target="_blank"><i class="fa-brands fa-pinterest"></i></a>
                  <?php } ?>
 
								</div>
							</li>
						</ul>
					</div>
				</div>
			</div>
			

      	<!-- Header -->
			<header class="header doccure_header header-custom header-fixed inner-header relative <?php echo esc_attr($header_class); ?> <?php echo esc_attr( doccure_header_classes() ); ?>">
				<div class="container">
					<nav class="navbar navbar-expand-lg header-nav">
						<div class="navbar-header">
							<a id="mobile_btn" href="javascript:void(0);">
								<span class="bar-icon">
									<span></span>
									<span></span>
									<span></span>
								</span>
							</a>
							<a href="<?php echo esc_url(get_home_url()); ?>" class="navbar-brand logo">
   <?php $logo_obj = doccure_get_option('site-logo');
 
 $logo_url = isset($logo_obj['url']) && !empty($logo_obj['url']) 
 ? $logo_obj['url'] 
 : get_template_directory_uri() . '/assets/images/logo.svg';
?><img src="<?php echo esc_url($logo_url); ?>" class="img-fluid" alt="Logo">       
 </a>


						</div>

            <div class="header-menu">
							<div class="main-menu-wrapper">
								<div class="menu-header">
									<a href="<?php echo esc_url(get_home_url()); ?>" class="menu-logo">
                  <img src="<?php echo esc_url($logo_url); ?>" class="img-fluid" alt="Logo">     
                			 	</a>
									<a id="menu_close" class="menu-close" href="javascript:void(0);">
										<i class="fas fa-times"></i>
									</a>
								</div>
                <?php doccure_nav_menu(); ?>


                
                <?php
         global $current_user;
		wp_get_current_user();

    if (is_user_logged_in()) { ?>


    <?php
    } else { 
      
      if(doccure_get_option('display-cta-button')) {
        
 $header_cta_btn_title = doccure_get_option('header_cta_btn_title');
$header_cta_btn_link = doccure_get_option('header_cta_btn_link');
// if (!$header_cta_btn_title || !$header_cta_btn_link) {
//     return;
// }

$header_cta_rbtn_title = doccure_get_option('header_cta_rbtn_title');
$header_cta_rbtn_link = doccure_get_option('header_cta_rbtn_link');
// if (!$header_cta_rbtn_title || !$header_cta_rbtn_link) {
//     return;
// }

?>
     
<?php if( !empty( $user_registration ) ){ ?>
 <div class="only_mobile_login_register">
  <ul class="main-nav">
							 
  <?php if( !empty( $is_login && (!empty($header_cta_btn_title) || !empty($header_cta_btn_link))) ){ ?>
    <li>
									<a href="<?php echo esc_html($header_cta_btn_link); ?>" class="btn btn-md btn-primary-gradient inline-flex align-items-center rounded-pill"><i class="isax isax-lock-1 me-1"></i><?php echo esc_html($header_cta_btn_title); ?></a>
								</li>
                <?php } ?>
                <?php if( !empty( $is_register ) && (!empty($header_cta_rbtn_title) || !empty($header_cta_rbtn_link)) ){ ?>
								<li>
									<a href="<?php echo esc_html($header_cta_rbtn_link); ?>" class="btn btn-md btn-dark inline-flex align-items-center register_button rounded-pill">
										<i class="isax isax-user-tick me-1"></i><?php echo esc_html($header_cta_rbtn_title); ?>
									</a>
								</li>
                <?php } ?>
							</ul>
              </div>
 
<?php } }  } ?>

              </div>
            </div>

                <?php
         global $current_user;
		wp_get_current_user();

    if (is_user_logged_in()) { ?>


    <?php
    } else { 
      
      if(doccure_get_option('display-cta-button')) {
        
 $header_cta_btn_title = doccure_get_option('header_cta_btn_title');
$header_cta_btn_link = doccure_get_option('header_cta_btn_link');
// if (!$header_cta_btn_title || !$header_cta_btn_link) {
//     return;
// }

$header_cta_rbtn_title = doccure_get_option('header_cta_rbtn_title');
$header_cta_rbtn_link = doccure_get_option('header_cta_rbtn_link');
// if (!$header_cta_rbtn_title || !$header_cta_rbtn_link) {
//     return;
// }

?>
     
<?php if( !empty( $user_registration ) ){ ?>
 
  <ul class="nav header-navbar-rht">
							 
  <?php if( !empty( $is_login && (!empty($header_cta_btn_title) || !empty($header_cta_btn_link))) ){ ?>
    <li>
									<a href="<?php echo esc_html($header_cta_btn_link); ?>" class="btn btn-md btn-primary-gradient inline-flex align-items-center rounded-pill"><i class="isax isax-lock-1 me-1"></i><?php echo esc_html($header_cta_btn_title); ?></a>
								</li>
                <?php } ?>
                <?php if( !empty( $is_register ) && (!empty($header_cta_rbtn_title) || !empty($header_cta_rbtn_link)) ){ ?>
								<li>
									<a href="<?php echo esc_html($header_cta_rbtn_link); ?>" class="btn btn-md btn-dark inline-flex align-items-center register_button rounded-pill">
										<i class="isax isax-user-tick me-1"></i><?php echo esc_html($header_cta_rbtn_title); ?>
									</a>
								</li>
                <?php } ?>
							</ul>

 
<?php } }  } ?>


		<?php	if (is_user_logged_in()) {
			?>

<div class="nav-item dropdown">
		<a href="javascript:void(0)">
		<span class="user-img sss">
       <?php  echo get_avatar( get_current_user_id(), 80 ); ?>

		</span>
		</a>
		<div class="dropdown-menu-end">
		<div class="user-header">
		<div class="avatar avatar-sm">
       <?php echo get_avatar( get_current_user_id(), 80 ); ?>

		</div>
		<div class="user-text">
		<h6><?php  echo  esc_html($current_user->user_login); ?></h6>
		<p class="text-success mb-0">
			<?php 
			$role = $current_user->roles[0];
			$role_name = $role ? wp_roles()->get_names()[ $role ] : '';
			echo esc_html($role_name);
			?>
		</p>
		</div>
		</div>
     
          
          <a href='<?php doccure_Profile_Menu::doccure_profile_menu_link('insights', get_current_user_id()); ?>' class='dropdown-item'><?php esc_html_e('Dashboard', 'doccure'); ?></a>		
		<a class="dropdown-item" href="<?php echo wp_logout_url( home_url() ); ?>"><?php esc_html_e('Logout', 'doccure'); ?></a>
		</div>
</div>
			<?php } ?> 
					 
					</nav>
				</div>
			</header>
			<!-- /Header -->