/var/www/(Del)hsihk.com/wp-content/themes/flatsome/page-my-account.php


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<?php
/*
Template name: My Account Sidebar
This templates add My account to the sidebar. 
*/

global $post$yith_wcwl;

$current_url get_permalink();
$wishlist_url '';

if (
in_array'yith-woocommerce-wishlist/init.php'apply_filters'active_plugins'get_option'active_plugins' ) ) ) ) { 
$wishlist_url $yith_wcwl->get_wishlist_url();
}

$myaccount_page_id get_option'woocommerce_myaccount_page_id' );
$myaccount_page get_permalink$myaccount_page_id );

if (!
is_user_logged_in() && $current_url != $myaccount_page && $wishlist_url != $current_url) {
  
header"Location: $myaccount_page);
}

get_header(); 
?>
<?php 
if(in_array'nextend-facebook-connect/nextend-facebook-connect.php'apply_filters'active_plugins'get_option'active_plugins' ) ) ) && $flatsome_opt['facebook_login'] && get_option('woocommerce_enable_myaccount_registration')=='yes' && !is_user_logged_in())  { ?> 
<div id="facebook-login" class="ux_banner dark" style="height:180px">
        <div class="banner-bg" style="background-image:url('<?php echo $flatsome_opt['facebook_login_bg']; ?>');background-color:#ddd"></div>
        <div class="row">
              <div class="inner center  text-center " style="width: 60%;">
                  <div class="inner-wrap animated fadeInDown">
                          <a href="<?php echo wp_login_url(); ?>?loginFacebook=1&redirect=<?php echo the_permalink(); ?>" class="button large facebook-button " onclick="window.location = '<?php echo wp_login_url(); ?>?loginFacebook=1&redirect='+window.location.href; return false;"><i class="icon-facebook"></i><?php _e('Login / Register with <strong>Facebook</strong>','flatsome'); ?></a>
                          <p><?php echo $flatsome_opt['facebook_login_text']; ?></p>
                  </div>
             </div>  
         </div>
</div>
<?php ?>    

<?php if( has_excerpt() ) { ?>
<div class="page-header">
    <?php the_excerpt(); ?>
</div>
<?php ?>

<div  class="page-wrapper my-account">
<div class="row">
<div id="content" class="large-12 columns" role="main">

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

<div class="row collapse vertical-tabs">
<div class="large-3 columns">
    <?php if(is_user_logged_in()){?>
        <div class="account-user hide-for-small">
        <?php 
                 $current_user 
wp_get_current_user();
                 
$user_id $current_user->ID;
                echo 
get_avatar$user_id60 );
        
?>

        <span class="user-name"><?php echo $current_user->display_name?> <em><?php echo '#'.$user_id;?></em></span>
           <span class="logout-link"><a href="<?php echo wp_logout_url(); ?>"><?php _e('Logout','woocommerce'); ?></a></span>         

        <br>
    </div>
    <?php ?>
    <div class="account-nav">
         <?php if ( has_nav_menu'my_account' ) ) : ?>
            <?php  
                    wp_nav_menu
(array(
                        
'theme_location' => 'my_account',
                        
'menu_class'      => 'tabs-nav',
                        
'depth' => 0,
                    ));
            
?>
         <?php else: ?>
            Define your 'My Account' navigation <b>Apperance > Menus</b>
        <?php endif; ?>
    </div><!-- .account-nav -->
</div><!-- .large-3 -->

<div class="large-9 columns">
    <div class="tabs-inner active">        
    

            <?php while ( have_posts() ) : the_post(); ?>
                <h1><?php the_title(); ?></h1>

                <?php the_content(); ?>
            
            <?php endwhile; // end of the loop. ?>        


    </div><!-- .tabs-inner -->
    </div><!-- .large-9 -->
</div><!-- .row .vertical-tabs -->

<?php } else { ?>  
    
        <?php while ( have_posts() ) : the_post(); ?>
            <h1><?php the_title(); ?></h1>

            <?php the_content(); ?>
        
        <?php endwhile; // end of the loop. ?>        

<?php ?>


</div><!-- end #content large-12 -->
</div><!-- end row -->
</div><!-- end page-right-sidebar container -->



<?php get_footer(); ?>