Skip to content

Instantly share code, notes, and snippets.

@DeskWOW
Last active June 27, 2017 18:46
Show Gist options
  • Save DeskWOW/93fc54fcccf9cb01b0bb to your computer and use it in GitHub Desktop.
Save DeskWOW/93fc54fcccf9cb01b0bb to your computer and use it in GitHub Desktop.
User Login/Page Test
<!-- Testing User/Page -->
{% if page == "login" or page == "forgot_password" or page == "registration" or page == "authentication_verification" or page == "email_new" or page == "email_pre_create" or page == "email_submitted" %}
{% assign Protected = false %}
{% else %}
{% if current_user and current_user.is_guest == false %}
{% assign Protected = false %}
{% else %}
{% assign Protected = true %}
{% endif %}
{% endif %}
<!-- Body Section -->
{% if Protected == true %}
<div id="support-main">
<div class="support-body">
<div class="content dashboard">
<h3>Please Login</h3>
</div>
</div>
</div>
{% else %}
{{desk:body}}
{% endif %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment