-
-
Save jamiemitchell/c0b91c61bb7a2076cf6b85a0a20e61cd to your computer and use it in GitHub Desktop.
ACF If Else field
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if ( get_field( 'field_name' ) ): ?> | |
This is displayed when the field_name is TRUE or has a value. | |
<?php else: // field_name returned false ?> | |
This is displayed when the field is FALSE, NULL or the field does not exist. | |
<?php endif; // end of if field_name logic ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment