You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Michael Xian edited this page Nov 4, 2018
·
8 revisions
Custom Fields Used
Paragraph
Paragraph (ACF)
This ACF has 2 fields.
The fields are as follows:
Enable Paragraph (True/False)
Whether or not to display this paragraph
Paragraph (Text)
The text in the body of the paragraph
To display this in a template, insert the following code block
<?php$paraEnabled = get_field("paragraph-enabled");
if ($paraEnabled) { // Set up varialbes if the paragraph was enabled$para = get_field("paragraph");
if ($para) { // If there is something in paragraph, display itecho"<p>${para}</p>";
}
}
?>