Remove FOUC issue on member detail pages
authorLaury GvR <laury@gaslightmedia.com>
Thu, 12 Sep 2019 21:17:42 +0000 (17:17 -0400)
committerLaury GvR <laury@gaslightmedia.com>
Thu, 12 Sep 2019 21:17:42 +0000 (17:17 -0400)
glm-member-db/views/front/members/detail.html
header.php

index bb6f613..251bbbe 100755 (executable)
             });
 
             // Automatically zoom and expand the relevant
-            $('html').addClass('glmassociatememberdetail glmassociatetop');
+            //$('html').addClass('glmassociatememberdetail glmassociatetop');
             if ("{$expanded}" != "") {
                 var expandTarget = "glm-member-detail-{$expanded}";
                 if ($("#"+expandTarget+"-container").length) {
index f2346c3..d21a9ad 100644 (file)
@@ -34,7 +34,7 @@ window._fbq.push(['track', 'PixelInitialized', {}]);
 <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-THMQFDZ');</script>
 <!-- End Google Tag Manager -->
   </head>
-  <body>
+  <body class="<?php if (is_member()) { echo 'glmassociatememberdetail glmassociatetop'; } ?>">
 <!-- Google Tag Manager (noscript) -->
 <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-THMQFDZ" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
 <!-- End Google Tag Manager (noscript) -->