Sidebar content now on every page that has text in MultiContentBlock admin-side.
authorLaury GvR <laury@gaslightmedia.com>
Tue, 19 May 2015 15:26:48 +0000 (11:26 -0400)
committerLaury GvR <laury@gaslightmedia.com>
Tue, 19 May 2015 15:26:48 +0000 (11:26 -0400)
page.php
parts/right-sidebar.php

index f049b1a..57477d0 100644 (file)
--- a/page.php
+++ b/page.php
@@ -2,7 +2,7 @@
                 <main>
                     <div class="row" data-equalizer>
                         <?php get_sidebar(); ?>
-                        <?php if (is_page("Courts & Sheriff")) { ?>
+                        <?php if (get_the_block( $name, $args ) != "") { ?>
                         <div id="content-bulk" class="small-12 large-6 columns" data-equalizer-watch>
                         <?php } else { ?>
                         <div id="content-bulk" class="small-12 large-9 columns" data-equalizer-watch>
@@ -29,7 +29,7 @@
                                 </div>
                             </footer>
                         </div>
-                        <?php if (is_page('Courts & Sheriff')) {
+                        <?php if (get_the_block( $name, $args ) != "") {
                             get_template_part('parts/right-sidebar');
                         } ?>
                     </div>
index f7d2497..aa3cae8 100644 (file)
@@ -1,7 +1,8 @@
 <div id="extra" class="large-3 columns show-for-large-up">
 <?php 
 echo get_the_block( $name, array(
-    'label'         => __( 'Admin label', 'text-domain' ),
+    'label'         => __( '<h2>Enter your Sidebar content here. Leave this blank '
+            . 'to remove the sidebar area once more<h2>', 'text-domain' ),
     'type'          => 'editor',
     'apply_filters' => true,
 ) );