Created
December 1, 2013 16:55
-
-
Save jrstaatsiii/7736698 to your computer and use it in GitHub Desktop.
Issue with ACF Post Object
This file contains hidden or 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('ssm_featured_course', 'options') ) { ?> | |
<?php $post_object = get_field('ssm_featured_course', 'options'); ?> | |
<?php $post = $post_object; ?> | |
<?php setup_postdata( $post ); ?> | |
<div id="featured-course"> | |
<div class="wrap"> | |
<small>Featured Course</small> | |
<p class="faux-title"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></p> | |
<?php if ( get_field('ssm_course_description') ) { ?> | |
<div class="course-description"> | |
<?php the_field('ssm_course_description'); ?> | |
</div> | |
<!-- end .course-description--> | |
<?php } ?> | |
<a class="button red" href="<?php the_permalink(); ?>">View Course</a> | |
</div> | |
<!-- end .wrap --> | |
</div> | |
<!-- end #featured-course --> | |
<?php wp_reset_postdata(); ?> | |
<?php } ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment