Wordpressのダッシュボードの外観→カスタマイズ→追加css
で以下のコードを追記する
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
@media only screen and (min-width: 960px){ .full-width-content.full-containar .content{ width:100%; } .full-width-content.full-containar .site-inner{ max-width:100%; } .full-width-content.full-containar .breadcrumb, .full-width-content.full-containar .entry-header, .full-width-content.full-containar .center-block, .full-width-content.full-containar .yarpp-related, .full-width-content.full-containar .entry-footer, .full-width-content.full-containar .comment-respond, .full-width-content.full-containar .after-entry{ max-width:700px; margin-left:auto; margin-right:auto; } } |
このCSSを投稿画面で全幅レイアウトを選び、
「Custom Body Class」に「full-containar」と入力
投稿画面のhtmlは下記のように入力
1 2 3 4 5 6 |
<div class="center-block"> 中央に寄せたい本文をここに入力 100%のグラフはこのブロックの外側に入力 </div> |