-
Notifications
You must be signed in to change notification settings - Fork 0
/
single.php
39 lines (35 loc) · 1.91 KB
/
single.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<!-- This is for the single projects / posts -->
<?php get_header(); ?> <!-- get header.php file -->
<div id="sidebar_menu">
<?php get_sidebar(); ?> <!-- get sidebar.php -->
</div><!-- sidebar_menu -->
<div class="main">
<?php if (has_tag('Ongoing')) { ?>
<h1 class="highlightColor"><?php echo get_the_title(); ?> <span class="light">(ongoing)</span></h1> <!-- get title of page -->
<?php } else { ?>
<h1 class="highlightColor"><?php echo get_the_title(); ?></h1> <!-- get title of page -->
<?php } ?>
<!-- Start the loop -->
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<?php the_post_thumbnail('full'); ?> <!-- display the full size feature image of the current post -->
<div class="project_description">
<p class="highlightColor">Project Description</p>
<p><?php the_field('project_description'); ?></p> <!-- accessing advanced custom field data - see: http://www.advancedcustomfields.com/ for more info -->
<br/>
<p class="highlightColor">Year</p>
<?php if (has_tag('Ongoing')) { ?>
<p>ongoing</p> <!-- display Work in Progress -->
<?php } else { ?>
<p><?php the_date('Y'); ?></p> <!-- Display year when project ended -->
<?php } ?>
<br/>
<p class="highlightColor">Categories</p>
<ul class="categories_ul">
<?php exclude_post_categories("40"); ?> <!-- list all categories but exclude cat 19 (Portfolio). See functions.php for more info or visit http://wordpress.stackexchange.com/questions/31181/exclude-categories-from-the-category -->
</ul>
</div>
<?php the_content(); ?> <!-- display the content of the current post -->
<?php endwhile; endif; ?>
<!-- End the loop -->
<br class="clear" /> <!-- remove all floats -->
<?php get_footer(); ?>