Page::getCurrentPage()->isComposerView???????

Permalink
I have a block that adds custom scroll bars. I have disabled it in edit mode with
<?php if (!Page::getCurrentPage()->isEditMode()) { ?>

But my block also messes with composer view. My block disables normal scrolling and controls the scrolling itself, but it doesn't work when composer is open. Nothing moves when you scroll. It was the same way in edit mode, but I know how to disable it in edit mode.

But how can I disable a block if composer is open?

Thanks,
David

ob7dev
 
ob7dev replied on at Permalink Best Answer Reply
ob7dev
I learned how to disable the script if the user is logged in altogether, which solves the problem in this case:
http://concrete5.org/api/class-Concrete.Core.User.User.html...

<?php 
$u = new User;
if (!$u->isSuperUser() ) { ?>
<script src="<?= $view->getThemePath() ?>/js/scripts.js"></script>
<?php } //end of check if logged in mode ?>