Skip to content

Instantly share code, notes, and snippets.

@yankeyhotel
Created September 17, 2014 14:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yankeyhotel/418d69c0bd0ac82109d4 to your computer and use it in GitHub Desktop.
Save yankeyhotel/418d69c0bd0ac82109d4 to your computer and use it in GitHub Desktop.
Use Switchee to replace and easy if else statement in ExpressionEngine
{exp:switchee variable="{variable_to_test_against}" parse="inward"}
{case value="''"}
<!-- value is empty -->
{/case}
{case default="Yes"}
<!-- default -->
{/case}
{/exp:switchee}
@yankeyhotel
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment