Edit bar not showing on *some* pages

Permalink 1 user found helpful
Hi all,

One of my sites has an odd problem. When logged in, the edit bar does not show any buttons on some pages, maybe 3-4. On the other pages, the buttons do show just fine. On these 3-4 pages, the <div id="ccm-toolbar"> is completely empty. These pages share a page type with many other pages that do show the edit bar buttons.

I tried clearing the cache, which did nothing. I am running 5.5.2.1 on this site. Anyone know if this is an issue with this version?

If not, any other ideas on how to fix this?

Thanks,
Colin

CygnetMidwest
 
Adreco replied on at Permalink Reply
Adreco
Have you installed any particular Add-On of Block to just those pages? If that's the case, it could be creating a conflict. If you believe that's the case, you should be able to revert to an earlier page version without the block installed from your sitemap.
CygnetMidwest replied on at Permalink Reply
CygnetMidwest
No, I have not installed any add-ons recently to this site. I made a few edits a few months ago. At that time ,the edit bar worked. Recently, the client made some edits and that's when it stopped showing on these pages.

I have tried to go back to earlier versions of the page with no luck in getting the edit bar to show.

Any other ideas? I'm completely stumped and my client is not happy...
ptityop replied on at Permalink Reply
where did you put <?php
Loader::element('footer_required');
?>
Can you send your code or a link to the page ? That will help
CygnetMidwest replied on at Permalink Reply
CygnetMidwest
Here is the URL of one of the pages that is not showing the edit bar:
http://www.4streets.com/index.php/products/stain-removal/wetdry/...

Here is the code for that page's template:
<?php 
defined('C5_EXECUTE') or die(_("Access Denied."));
$this->inc('elements/header.php'); ?>
      <div id="content">
         <div class="image">
            <?php 
            $a = new Area('Product image');
            $a->display($c);
            ?>
         </div>
         <?php 
         $a = new Area('Main');
         $a->display($c);
         ?>
      </div><!-- content ends -->


In the elements/footer.php file I have this:

<?php  defined('C5_EXECUTE') or die(_("Access Denied.")); ?>
<div id="footer">
   <div>
      <?php 
      $a = new Area('Footer');
      $a->display($c);
      ?>
   </div>
        <p><?php echo t('All content and design')?> ©<?php echo date('Y')?> <?php echo t('R.R. Street and Co. Inc., All rights reserved.')?></p>
</div><!-- footer ends -->
<?php  Loader::element('footer_required'); ?>
</body>
</html>


As I mentioned before, there are several (probably a couple of dozen) of pages using the same page type as the ones with this issue, and they work fine.

Thank you for any ideas or help you can give!
ptityop replied on at Permalink Reply
I would suggest you first try to correct most of the errors you'll see there

http://validator.w3.org/check?uri=http%3A%2F%2Fwww.4streets.com%2Fi...

It will then be easier to try and spot where your problem can come from ... your page code looks pretty odd to me really ...

While you're checking this, could you send a link to a page that uses the same template to see if there is something that can be spotted there
mhawke replied on at Permalink Best Answer Reply
mhawke
I'm not sure if this is causing it but check the <?php echo... ?> lines in your footer.php. They are missing closing semi-colons. Also, check to make sure your system is set to show php errors by going to "Dashboard->System and Settings->Debug Settings' (under Environment) and make sure it's set to 'Show errors in page'. Then on the offending pages, right-click and view the source of the page and scroll down to the bottom of the source to see if php errors are showing.
CygnetMidwest replied on at Permalink Reply
CygnetMidwest
Thanks for the tips ptityop and mhawke. I've fixed some of the errors.

I think the issue may be a custom add-on I had a contractor create for this site.

I still haven't completely solved the issue, but I'm closer. I went back to an old version of one page that did not have this add-on in it. That solved a secondary issue of the side menu not working correctly.

BUT, strangely, the current page version that is enabled does not show when I'm logged into the site. The old version with the bad add-on still show. I've cleared the cache (both C5 ad browser) and still shows.
mhawke replied on at Permalink Reply
mhawke
When you rolled back to a previous version, did you also delete the newer version with the bad add-on? The 'SuperAdmin' always sees the most recent version of a page when logged in even if a past version is officially 'approved'. You need to delete any versions newer than the approved version in order to stop seeing it when you log in.
CygnetMidwest replied on at Permalink Reply
CygnetMidwest
I did not. Just deleted the newer versions and now I see the correct one... with the edit bar!

Thanks again!
FocusedImage replied on at Permalink Reply
What also might be causing the issue as I have discovered with some of my own themes is that either you or an add-on as mentioned already is using some JavaScript or JQuery that is interfering with the JQuery of Concrete5. This can either cause the edit bar to appear but be blank or not to appear at all.

So you can always try removing each bit of JavaScript/JQuery until you find which is the problem.