Created
March 21, 2017 04:48
-
-
Save nyankichi-n-n/167fdd6e082b58698820fdf7efac7891 to your computer and use it in GitHub Desktop.
[デモ会員サイト構築]15. トップページにウィジェットを設定して、会員サイトである事を表示
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if(is_user_logged_in()){ ?> | |
<div class="user-name">こんにちは <?php global $current_user; echo $current_user->display_name ?> さん</div> | |
<?php } elseif (is_front_page()) { | |
dynamic_sidebar('top_main_widget'); | |
} ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment