Update for member and event detail pages.
authorSteve Sutton <steve@gaslightmedia.com>
Mon, 18 Sep 2017 12:52:50 +0000 (08:52 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Mon, 18 Sep 2017 12:52:50 +0000 (08:52 -0400)
Redo how to get title for the internal pages.

sections/interior-page.php

index bd61591..51a0e89 100644 (file)
@@ -1,7 +1,15 @@
 <main class="page-inside">
     <div id="page-title-container">
         <span class="page-title">
-            <?php echo $post->post_title; ?>
+            <?php
+            if ( is_member() ) {
+                echo get_member_name();
+            } else if ( glm_is_event_detail() ) {
+                echo glm_get_event_name();
+            } else {
+                echo get_the_title();
+            }
+            ?>
         </span>
     </div>
     <div id="content-wrapper">
@@ -11,7 +19,7 @@
                         <?php if (is_user_logged_in()) { ?>
                             <!-- If user is logged in as a member, display top bar, bread crumbs, & content -->
                             <?php get_template_part('parts/glm-members-only-top-bar');
-                            get_template_part('parts/main-content'); 
+                            get_template_part('parts/main-content');
                         } else {
                             get_template_part('parts/glm-members-only-login-form');
                         } ?>
@@ -20,7 +28,7 @@
                      <div class="small-12 columns">
                          <?php if(function_exists('bcn_display') && !is_front_page())
                          {
-                            echo "<div class=\"breadcrumbs small-12 columns\">"; 
+                            echo "<div class=\"breadcrumbs small-12 columns\">";
                             bcn_display();
                             echo "</div>";
                         }
@@ -41,4 +49,4 @@
 </main>
 <div class="row action-item-section">
     <?php get_template_part('parts/action-items');?>
-</div>
\ No newline at end of file
+</div>