-
-
Save jamiemitchell/1db65942a7214f02725e to your computer and use it in GitHub Desktop.
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
| /** Loop for Projects **/ | |
| $loop = new WP_Query( $args ); | |
| if( $loop->have_posts() ): | |
| echo '<div id="container">'; | |
| while( $loop->have_posts() ): $loop->the_post(); | |
| echo '<div class="projects one-third '.genesis_get_custom_field('program') . ' ' .genesis_get_custom_field('project_type') . ' ' .genesis_get_custom_field('country') . '">'; | |
| echo '<h2><a href="' . get_permalink() . '">' . get_the_title() . '</a></h2>'; | |
| echo '<a href="' . get_permalink() . '">' . get_the_post_thumbnail( $post_id, 'project' ). '</a>'; | |
| echo '<h3 class="mmi-country ' . genesis_get_custom_field('country') . '">' . genesis_get_custom_field('country') . '</h3>'; | |
| echo '<div class="project-details">'; | |
| echo '<p>'; | |
| echo date('m/d/Y', $startdate); | |
| echo ' to '; | |
| echo date('m/d/Y', $finishdate); | |
| echo '</p>'; | |
| if(genesis_get_custom_field('mmi_director_email')) { | |
| echo '<p><strong>Director:</strong> <a href="mailto:' . genesis_get_custom_field('mmi_director_email') . '">' . genesis_get_custom_field('mmi_director') . '</a></p>'; | |
| } else { | |
| echo '<p><strong>Director:</strong> ' . genesis_get_custom_field('mmi_director') . '</p>'; | |
| } | |
| echo '<p><strong>Type:</strong> ' . genesis_get_custom_field('project_type') . '</p>'; | |
| if(genesis_get_custom_field('mmi_project_coordinator_email')){ | |
| echo '<p><strong>Coordinator:</strong> <a href="mailto:' . genesis_get_custom_field('mmi_project_coordinator_email') . '">' . genesis_get_custom_field('mmi_project_coordinator') . '</a></p>'; | |
| } else { | |
| echo '<p><strong>Coordinator:</strong> ' . genesis_get_custom_field('mmi_project_coordinator') . '</p>'; | |
| } | |
| echo '</div>'; | |
| echo '<a class="button" href="' . get_permalink() . '">Read More . . .</a>'; | |
| echo '</div>'; | |
| endwhile; | |
| ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment