Beispiel #1
0
<?php 
}
//サイドバーの背景色を白色にするか
if (is_sidebar_background_white()) {
    ?>
/*サイドバーの背景色を白色*/
#sidebar{
  background-color: #fff;
  padding: 5px 8px;
  border-radius: 4px;
  border: 1px solid #ddd;
}
<?php 
}
//モバイルのシェアボタンをバイラルにするか
if (is_share_button_type_mobile_viral() && is_mobile()) {
    ?>
/*モバイルのシェアボタン*/
@media screen and (max-width:740px){
  .sns-group-viral ul.snsb li a {
      width: 130px;
      margin-bottom: 0;
  }
}
<?php 
}
//サイドバートップに広告を表示しているときモバイルで広告が2つかぶらないようにする
if (false && is_ads_sidebar_top() && is_mobile()) {
    ?>
.ad-article-bottom {
    margin-bottom: 200px;
<?php

//主にモバイル用に表情は早くするためのアイコンボタン
if (is_all_sns_share_btns_visible()) {
    $viral_class = is_share_button_type_mobile_viral() ? ' sns-group-viral' : '';
    ?>
<div class="sns-buttons sns-buttons-icon<?php 
    echo $viral_class;
    ?>
">
  <?php 
    if (get_share_msg()) {
        //シェアボタン用のメッセージを取得
        ?>
  <p class="sns-share-msg"><?php 
        echo esc_html(get_share_msg());
        ?>
</p>
  <?php 
    }
    ?>
  <ul class="snsb clearfix snsbs">
    <?php 
    if (is_twitter_btn_visible()) {
        //Twitterボタンを表示するか
        ?>
  	<li class="twitter-btn-icon"><a href="//twitter.com/share?text=<?php 
        echo urlencode(get_the_title());
        ?>
&amp;url=<?php 
        echo urlencode(punycode_encode(get_permalink()));