• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP wc_customer_edit_account_url函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中wc_customer_edit_account_url函数的典型用法代码示例。如果您正苦于以下问题:PHP wc_customer_edit_account_url函数的具体用法?PHP wc_customer_edit_account_url怎么用?PHP wc_customer_edit_account_url使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了wc_customer_edit_account_url函数的19个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: get_url

 /**
  * @param $page
  */
 function get_url($page)
 {
     switch ($page) {
         case 'sign_out':
             return wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount'));
         case 'edit_account_url':
             return wc_customer_edit_account_url();
     }
 }
开发者ID:hoangsoft90,项目名称:hw-hoangweb-plugin,代码行数:12,代码来源:hw-woo-customer.php


示例2: printf

			<!-- Home header title -->
			<h1 class="page__title">
				<?php 
printf(__('Hello %1$s', 'woocommerce') . ' ', $current_user->display_name);
?>
			</h1>

			<div class="steps__frame">
				<p>
					<?php 
printf(__('Are you not %1$s? <a href="%2$s">Sign out</a>.', 'woocommerce') . ' ', $current_user->display_name, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
?>
<br>
					<?php 
printf(__('Here you can view your recent orders and <a href="%s">edit your password and account details</a>.', 'woocommerce'), wc_customer_edit_account_url());
?>
				</p>
			</div>

			<div class="home__intro__section__mascotte">
				
			</div>

		</section>

	</div>

<?php 
do_action('woocommerce_before_my_account');
?>
开发者ID:sebastiaandekker,项目名称:sd,代码行数:30,代码来源:my-account.php


示例3: laboutique_my_account_sidebar_nav

    function laboutique_my_account_sidebar_nav($args = array())
    {
        ?>
            <ul<?php 
        if ($args['class']) {
            ?>
 class="<?php 
            echo $args['class'];
            ?>
"<?php 
        }
        ?>
>
                <li><a href="<?php 
        echo get_permalink(get_option('woocommerce_myaccount_page_id'));
        ?>
" title="<?php 
        _e('My Account', DOMAIN);
        ?>
"><?php 
        _e('My Account', DOMAIN);
        ?>
</a></li>                                                    
                <?php 
        $myaccount_page_id = get_option('woocommerce_myaccount_page_id');
        if ($myaccount_page_id) {
            $logout_url = wp_logout_url(get_permalink($myaccount_page_id));
            if (get_option('woocommerce_force_ssl_checkout') == 'yes') {
                $logout_url = str_replace('http:', 'https:', $logout_url);
            }
        }
        ?>
                <li><a href="<?php 
        echo wc_customer_edit_account_url();
        ?>
" title=""><?php 
        echo __("Edit Account", DOMAIN);
        ?>
</a></li>
                
                <li><a href="<?php 
        echo wc_get_endpoint_url('edit-address', 'billing');
        ?>
"><?php 
        echo __("Edit Billing Address", DOMAIN);
        ?>
</a></li>
                <li><a href="<?php 
        echo wc_get_endpoint_url('edit-address', 'shipping');
        ?>
"><?php 
        echo __("Edit Shipping Address", DOMAIN);
        ?>
</a></li>    
                
                <li><a href="<?php 
        echo get_permalink(get_option('woocommerce_cart_page_id'));
        ?>
"><?php 
        echo _e('Shopping cart', DOMAIN);
        ?>
</a></li>
                
                <li><a href="<?php 
        echo $logout_url;
        ?>
" title="<?php 
        _e('Logout', DOMAIN);
        ?>
"><?php 
        _e('Logout', DOMAIN);
        ?>
</a></li>
            </ul>

            
        <?php 
    }
开发者ID:ravenvn,项目名称:sandau,代码行数:78,代码来源:woocommerce.php


示例4: bearded_woocommerce_nav

function bearded_woocommerce_nav()
{
    global $wp, $post, $yith_wcwl;
    if (function_exists('is_woocommerce')) {
        ?>
    <nav class="shop-nav">
        <ul class="account-menu">
            <?php 
        if (is_user_logged_in()) {
            ?>
 
            <li class="my-account <?php 
            echo !empty($post) && $post->ID == wc_get_page_id('myaccount') && !array_key_exists(get_option('woocommerce_myaccount_edit_account_endpoint'), $wp->query_vars) ? 'active' : '';
            ?>
">
                <a class="tiptip icon-user" title="<?php 
            _e('My Account', 'bearded');
            ?>
" href="<?php 
            echo get_permalink(wc_get_page_id('myaccount'));
            ?>
">
                    <span class="link-title"><?php 
            _e('My Account', 'bearded');
            ?>
</span>
                </a>
            </li>
            <li class="edit-account <?php 
            echo !empty($post) && $post->ID == wc_get_page_id('myaccount') && array_key_exists(get_option('woocommerce_myaccount_edit_account_endpoint'), $wp->query_vars) ? 'active' : '';
            ?>
">
                <a class="tiptip icon-pencil" title="<?php 
            _e('Edit Account', 'bearded');
            ?>
" href="<?php 
            echo wc_customer_edit_account_url();
            ?>
">
                    <span class="link-title"><?php 
            _e('Edit Account', 'bearded');
            ?>
</span>
                </a>
            </li>
            <li class="visit-shop <?php 
            echo get_query_var('post_type') == 'product' ? 'active' : '';
            ?>
">
                <a class="tiptip icon-home" title="<?php 
            _e('Visit Shop', 'bearded');
            ?>
" href="<?php 
            echo get_permalink(wc_get_page_id('shop'));
            ?>
">
                    <span class="link-title"><?php 
            _e('Visit Shop', 'bearded');
            ?>
</span>
                </a>
            </li>
            <?php 
            if ($yith_wcwl) {
                ?>
            <li class="wishlist <?php 
                echo !empty($post) && $post->ID == get_option('yith_wcwl_wishlist_page_id') ? 'active' : '';
                ?>
">
                <a class="tiptip icon-magic" title="<?php 
                _e('View Wishlist', 'bearded');
                ?>
" href="<?php 
                echo $yith_wcwl->get_wishlist_url();
                ?>
">
                    <span class="link-title"><?php 
                _e('View Wishlist', 'bearded');
                ?>
</span>
                </a>
            </li>
            <?php 
            }
            ?>
            <li class="logout">
                <a class="tiptip icon-signout" title="<?php 
            _e('Logout', 'bearded');
            ?>
" href="<?php 
            echo wp_logout_url($_SERVER['REQUEST_URI']);
            ?>
">
                    <span class="link-title"><?php 
            _e('Logout', 'bearded');
            ?>
</span>
                </a>
            </li>
            <?php 
//.........这里部分代码省略.........
开发者ID:jahir07,项目名称:bearded,代码行数:101,代码来源:functions-woocommerce.php


示例5: get_first_name

				<p>Nombre: <strong><?php 
echo get_first_name();
?>
</strong></p>
				<p>Apellido: <strong><?php 
echo get_last_name();
?>
</strong></p>
				<p>Correo: <strong><?php 
echo get_email();
?>
</strong></p>

				<div class="[ text-left ][ margin-top ]">
					<?php 
printf(__('<a class="[ color-primary ][ btn btn-primary btn-hollow btn-sm ][ inline-block ]" href="%s">editar detalles</a>', 'woocommerce'), wc_customer_edit_account_url());
?>
				</div>
			</section>

			<?php 
wc_get_template('myaccount/my-address.php');
?>

		</div>

		<div class="[ col-xs-12 col-sm-6 ]">
			<?php 
do_action('woocommerce_before_my_account');
?>
开发者ID:javolero,项目名称:dabba,代码行数:30,代码来源:my-account.php


示例6: printf

      <li role="presentation"><a href="#orders" aria-controls="orders" role="tab" data-toggle="tab">My Orders</a></li>

      <li role="presentation"><a href="#address" aria-controls="address" role="tab" data-toggle="tab">My Addresses</a></li>

      <li role="presentation"><a href="#accountsettings" aria-controls="address" role="tab" data-toggle="tab">My Account Settings</a></li>

    </ul>

    <div class="tab-content">

      <div role="tabpanel" class="tab-pane fade in active" id="dashboard">

        <?php 
printf(__('Hello <strong>%1$s</strong> (not %1$s? <a href="%2$s">Sign out</a>).', 'woocommerce') . ' ', $current_user->display_name, wp_logout_url(get_permalink(wc_get_page_id('myaccount'))));
printf(__('From your account dashboard you can view your recent orders, manage your shipping and billing addresses.', 'woocommerce'), wc_customer_edit_account_url());
?>

      </div>

      <div role="tabpanel" class="tab-pane fade" id="downloads">

        <?php 
wc_get_template('myaccount/my-downloads.php');
?>

      </div>

      <div role="tabpanel" class="tab-pane fade" id="orders">

        <?php 
开发者ID:VLabsInc,项目名称:WordPressPlatforms,代码行数:30,代码来源:my-account.php


示例7: wc_print_notices

<?php

/**
 * My Account page
 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
wc_print_notices();
echo beans_open_markup('woo_my_account_user', 'p', array('class' => 'myaccount_user'));
printf(__('Hello ' . beans_open_markup('woo_my_account_user_name', 'strong') . '%1$s' . beans_close_markup('woo_my_account_user_name', 'strong') . ' (not %1$s? ' . beans_open_markup('woo_my_account_user_logout_link', 'a', array('href' => '%2$s')) . 'Sign out' . beans_close_markup('woo_my_account_user_logout_link', 'a'), 'woocommerce') . ' ', $current_user->display_name, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
printf(__('From your account dashboard you can view your recent orders, manage your shipping and billing addresses and ' . beans_open_markup('woo_my_account_user_account_link', 'a', array('href' => '%s')) . 'edit your password and account details' . beans_close_markup('woo_my_account_user_account_link', 'a'), 'woocommerce'), wc_customer_edit_account_url());
echo beans_close_markup('woo_my_account_user', 'p');
do_action('woocommerce_before_my_account');
wc_get_template('myaccount/my-downloads.php');
wc_get_template('myaccount/my-orders.php', array('order_count' => $order_count));
wc_get_template('myaccount/my-address.php');
do_action('woocommerce_after_my_account');
开发者ID:simondowdles,项目名称:woocommerce-overrides-for-beans,代码行数:23,代码来源:my-account.php


示例8: wc_print_notices

 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
    // Exit if accessed directly
}
wc_print_notices();
?>

<p class="myaccount_user">
	<?php 
// print_r($current_user);
printf(__('Hello <strong>%1$s</strong> (not %1$s? <a href="%2$s">Sign out</a>).', 'woocommerce') . ' ', $current_user->user_email, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
printf(__('From your account dashboard you can view your recent orders, manage your shipping and billing addresses and <a href="%s">edit your password and account details</a>.', 'woocommerce'), wc_customer_edit_account_url());
?>
</p>

<?php 
do_action('woocommerce_before_my_account');
?>

<?php 
wc_get_template('myaccount/my-downloads.php');
?>

<?php 
wc_get_template('myaccount/my-orders.php', array('order_count' => $order_count));
?>
开发者ID:willowmagrini,项目名称:dg,代码行数:30,代码来源:OLD-my-account.php


示例9: wc_print_notices

 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
    // Exit if accessed directly
}
wc_print_notices();
?>

<p class="myaccount_user">
	<?php 
echo '<div class="woocommerce-info">';
printf(__('Hello <strong>%1$s</strong> (not %1$s? <a href="%2$s">Sign out</a>).', 'woocommerce') . ' ', $current_user->display_name, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
printf(__('From your account dashboard you can <a href="%s">edit your password and account details</a>.', 'woocommerce'), wc_customer_edit_account_url());
echo '</div>';
?>
</p>

<?php 
do_action('woocommerce_before_my_account');
?>

<?php 
wc_get_template('myaccount/my-downloads.php');
?>

<?php 
wc_get_template('myaccount/my-orders.php', array('order_count' => $order_count));
?>
开发者ID:sumeetbajra,项目名称:jewelleryshop,代码行数:31,代码来源:my-account.php


示例10: wc_print_notices

 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
    // Exit if accessed directly
}
wc_print_notices();
?>
<div class="sidebar-primary row account-downloads">
<div class="sidebar">
<h2>Account Details <small>
    <?php 
printf(__('[<a href="%s">Edit</a>]', 'woocommerce'), wc_customer_edit_account_url());
?>
</small></h2>
<p class="myaccount_user">
	<?php 
printf(__('<strong>%1$s</strong>', 'woocommerce') . ' ', $current_user->user_email, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
?>
</p>
<?php 
wc_get_template('myaccount/my-address.php');
?>

</div>

<?php 
wc_get_template('myaccount/my-downloads.php');
开发者ID:romapad,项目名称:sound-themplate,代码行数:31,代码来源:my-account.php


示例11: wc_print_notices

 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $woocommerce;
wc_print_notices();
?>

<p class="myaccount_user">

	<?php 
printf(__('Hello, <strong>%1$s</strong> (not %1$s? <a href="%2$s">Sign out</a>)', 'yit') . __('From your account dashboard you can view your recent orders, manage your shipping and billing addresses and <a href="%3$s">change your password</a>.', 'yit'), $current_user->display_name, wp_logout_url(get_permalink(wc_get_page_id('myaccount'))), wc_customer_edit_account_url());
?>
</p>

<?php 
do_action('woocommerce_before_my_account');
?>

<?php 
wc_get_template('myaccount/my-downloads.php');
?>

<?php 
wc_get_template('myaccount/my-orders.php', array('order_count' => $order_count));
?>
开发者ID:zgomotos,项目名称:Bazar,代码行数:30,代码来源:my-account.php


示例12: get_myaccount_url

 /**
  * Get My Account URL
  *
  * @return string Formatted URL string
  */
 public static function get_myaccount_url()
 {
     if (self::is_wc_2_1()) {
         return wc_customer_edit_account_url();
     } else {
         return get_permalink(woocommerce_get_page_id('myaccount'));
     }
 }
开发者ID:GaryJones,项目名称:goombiel,代码行数:13,代码来源:class-wc-compat-ipay88.php


示例13: printf

<?php

global $opCliente;
?>
<div class="[ container ]"><!-- end ina my-address -->
	<div class="[ row ]">

		<section class="[ col-sm-3 ][ bg-gray-lighter ]">
			<article class="[ margin-bottom ]">
				<?php 
printf(__('<h2 class="[ no-margin ]">%1$s</h2> <a href="%2$s" class="[ underline ][ color-secondary ]"><em>salir</em></a>', 'woocommerce') . ' ', $current_user->display_name, wc_get_endpoint_url('customer-logout', '', wc_get_page_permalink('myaccount')));
printf(__('<a class="[ color-secondary ][ underline ]" href="%s"><em>editar</em></a>', 'woocommerce'), wc_customer_edit_account_url());
?>
			</article>

			<article>
				<?php 
wc_get_template('myaccount/my-address.php');
?>
			</article>

		</section>

		<section class="[ col-xs-12 col-sm-8 ]">
            <?php 
if ($opCliente->clubId == '' || $opCliente->clubId == 0) {
    ?>
                <article class="[ padding--bottom margin-bottom ]">
                    <p>Para continuar favor de seleccionar un club de consumo</p>
                    <form id="select-club" method="POST" class="select-club">
                        <table>
开发者ID:pcuervo,项目名称:wp-yolcan,代码行数:31,代码来源:dashboard.php


示例14: dokan_header_user_menu

    /**
     * User top navigation menu
     *
     * @return void
     */
    function dokan_header_user_menu()
    {
        ?>
    <ul class="nav navbar-nav navbar-right">
        <li>
            <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php 
        printf(__('Cart %s', 'dokan'), '<span class="dokan-cart-amount-top">(' . WC()->cart->get_cart_total() . ')</span>');
        ?>
 <b class="caret"></b></a>

            <ul class="dropdown-menu">
                <li>
                    <div class="widget_shopping_cart_content"></div>
                </li>
            </ul>
        </li>

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

            <?php 
            global $current_user;
            $user_id = $current_user->ID;
            if (dokan_is_user_seller($user_id)) {
                ?>
                <li class="dropdown">
                    <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php 
                _e('Seller Dashboard', 'dokan');
                ?>
 <b class="caret"></b></a>

                    <ul class="dropdown-menu">
                        <li><a href="<?php 
                echo dokan_get_store_url($user_id);
                ?>
" target="_blank"><?php 
                _e('Visit your store', 'dokan');
                ?>
 <i class="fa fa-external-link"></i></a></li>
                        <li class="divider"></li>
                        <?php 
                $nav_urls = dokan_get_dashboard_nav();
                foreach ($nav_urls as $key => $item) {
                    printf('<li><a href="%s">%s &nbsp;%s</a></li>', $item['url'], $item['icon'], $item['title']);
                }
                ?>
                    </ul>
                </li>
            <?php 
            }
            ?>

            <li class="dropdown">
                <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php 
            echo esc_html($current_user->display_name);
            ?>
 <b class="caret"></b></a>
                <ul class="dropdown-menu">
                    <li><a href="<?php 
            echo dokan_get_page_url('my_orders');
            ?>
"><?php 
            _e('My Orders', 'dokan');
            ?>
</a></li>
                    <li><a href="<?php 
            echo dokan_get_page_url('myaccount', 'woocommerce');
            ?>
"><?php 
            _e('My Account', 'dokan');
            ?>
</a></li>
                    <li><a href="<?php 
            echo wc_customer_edit_account_url();
            ?>
"><?php 
            _e('Edit Account', 'dokan');
            ?>
</a></li>
                    <li class="divider"></li>
                    <li><a href="<?php 
            echo wc_get_endpoint_url('edit-address', 'billing', get_permalink(wc_get_page_id('myaccount')));
            ?>
"><?php 
            _e('Billing Address', 'dokan');
            ?>
</a></li>
                    <li><a href="<?php 
            echo wc_get_endpoint_url('edit-address', 'shipping', get_permalink(wc_get_page_id('myaccount')));
            ?>
"><?php 
            _e('Shipping Address', 'dokan');
            ?>
</a></li>
//.........这里部分代码省略.........
开发者ID:abcode619,项目名称:wpstuff,代码行数:101,代码来源:template-tags.php


示例15: wc_print_notices

 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $woocommerce;
wc_print_notices();
?>

<p class="myaccount_user">
	<?php 
echo '<div class="bold myaccount_desc">';
printf(__('Welcome back, <span>%s</span> !', 'wpdance'), $current_user->display_name);
printf(__('</br><u><a class="bold" href="%s">Change password</a></u><br/>', 'wpdance'), esc_url(wc_customer_edit_account_url()));
echo '<u><a class="bold" href="' . wp_logout_url(get_permalink(woocommerce_get_page_id('myaccount'))) . '">' . __('Log out', 'wpdance') . '</a></u>';
echo '</div>';
?>
</p>

<?php 
do_action('woocommerce_before_my_account');
?>

<?php 
wc_get_template('myaccount/my-downloads.php');
?>

<?php 
wc_get_template('myaccount/my-orders.php', array('order_count' => $order_count));
开发者ID:mynein,项目名称:myne,代码行数:31,代码来源:my-account.php


示例16: woocommerce_customer_edit_account_url

/**
 * @deprecated
 */
function woocommerce_customer_edit_account_url()
{
    return wc_customer_edit_account_url();
}
开发者ID:nayemDevs,项目名称:woocommerce,代码行数:7,代码来源:wc-deprecated-functions.php


示例17: redirect

 /**
  * Redirect back to the provided return_url
  *
  * @since 1.0
  * @param string $type redirect type, currently only `error` or null
  * @param int $user_id the user ID. Default 0.
  */
 public function redirect($type = null, $user_id = 0)
 {
     $user = get_user_by('id', $user_id);
     if (isset($user->user_email) && '' === $user->user_email) {
         $return_url = add_query_arg('wc-social-login-missing-email', 'true', wc_customer_edit_account_url());
     } else {
         $return_url = get_transient('wcsl_' . md5($_SERVER['REMOTE_ADDR'] . $_SERVER['HTTP_USER_AGENT']));
         $return_url = $return_url ? esc_url(urldecode($return_url)) : SV_WC_Plugin_Compatibility::wc_get_page_permalink('myaccount');
         delete_transient('wcsl_' . md5($_SERVER['REMOTE_ADDR'] . $_SERVER['HTTP_USER_AGENT']));
     }
     if ('error' == $type) {
         // using a query arg because wc_add_notice() only works when the WC session is available
         // which is only on the cart/checkout pages
         $return_url = add_query_arg('wc-social-login-error', 'true', $return_url);
     }
     wp_redirect(esc_url_raw($return_url));
     exit;
 }
开发者ID:rsantellan,项目名称:wordpress-ecommerce,代码行数:25,代码来源:class-wc-social-login-opauth.php


示例18: wc_print_notices

 * @version     2.0.0
 */

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}

wc_print_notices(); ?>

<p class="myaccount_user">
	<?php
	printf(
		__( 'Not %1$s? <a href="%2$s">Sign out</a>.', 'yit' ) . ' ',
		$current_user->display_name,
		wp_logout_url( get_permalink( get_option( 'woocommerce_myaccount_page_id' ) ) )
	);

	printf( __( 'From your account dashboard you can view your recent orders, manage your shipping and billing addresses and <a href="%s">edit your password and account details</a>.', 'yit' ),
		wc_customer_edit_account_url()
	);
	?>
</p>

<?php do_action( 'woocommerce_before_my_account' ); ?>

<?php wc_get_template( 'myaccount/my-orders.php', array( 'order_count' => 1 ) ); ?>

<?php wc_get_template( 'myaccount/my-address.php' ); ?>

<?php do_action( 'woocommerce_after_my_account' ); ?>
开发者ID:jabue,项目名称:wordpress,代码行数:30,代码来源:my-account.php


示例19: widget

    public function widget($args, $instance)
    {
        $dash_notice_login = apply_filters('widget_dash_notice_login', @$instance['dash_notice_login']);
        $dash_notice_logout = apply_filters('widget_dash_notice_logout', @$instance['dash_notice_logout']);
        // Before and after the widget
        echo $args['before_widget'];
        // The Output
        ?>
<div class="dash-all">
	<?php 
        esc_html_e('Welcome', 'wise-blog');
        echo '&#44; ';
        ?>
	<div class="dash-gravatar"><?php 
        global $userdata;
        wp_get_current_user();
        echo wp_kses_post(get_avatar(@$userdata->ID, 50));
        ?>
</div>
	<h2 class="dash-name"><?php 
        if (is_user_logged_in()) {
            echo esc_attr(wp_get_current_user()->display_name);
        } else {
            esc_html_e('Guest', 'wise-blog');
        }
        ?>
</h2>		
	<?php 
        if (is_user_logged_in()) {
            ?>
		<div class="dash-tools">
			<a href="<?php 
            echo esc_url(home_url('/') . 'wp-admin/');
            ?>
"><?php 
            esc_html_e('Dashboard', 'wise-blog');
            ?>
</a>
			<?php 
            if (function_exists('is_woocommerce') && is_woocommerce()) {
                echo '<a class="dash-home" href="' . wc_customer_edit_account_url() . '">' . esc_html__('Edit Account', 'wise-blog') . '</a>';
            } else {
                echo '<a class="dash-home" href="' . esc_url(home_url('/') . 'wp-admin/profile.php') . '">' . esc_html__('Edit Account', 'wise-blog') . '</a>';
            }
            ?>
		</div>
		<a class="dash-out" href="<?php 
            echo wp_logout_url(home_url('/'));
            ?>
"><?php 
            esc_html_e('Log out', 'wise-blog');
            ?>
</a>
		<span class="dash-notice"><i><?php 
            echo esc_attr($dash_notice_login);
            ?>
</i></span>
	<?php 
        } else {
            ?>
		<div class="dash-tools">
			<a class="lg-in" href="<?php 
            if (function_exists('is_woocommerce')) {
                echo get_permalink(get_option('woocommerce_myaccount_page_id'));
            } else {
                echo esc_url(home_url('/') . 'wp-admin/');
            }
            ?>
"><?php 
            esc_html_e('Login', 'wise-blog');
            ?>
</a>
			<a class="lg-reg dash-home" href="<?php 
            echo esc_url(home_url('/') . 'wp-login.php?action=register');
            ?>
"><?php 
            esc_html_e('Register', 'wise-blog');
            ?>
</a>
		</div>
		<span class="dash-notice"><i><?php 
            echo esc_attr($dash_notice_logout);
            ?>
</i></span>
	<?php 
        }
        ?>
</div>
<?php 
        echo $args['after_widget'];
    }
开发者ID:Falkvinge,项目名称:BlogTheme2016,代码行数:91,代码来源:wise-dashboard-user.php



注:本文中的wc_customer_edit_account_url函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP wc_date_format函数代码示例发布时间:2022-05-23
下一篇:
PHP wc_customer_bought_product函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap