-
Notifications
You must be signed in to change notification settings - Fork 0
/
single-note.php
77 lines (73 loc) · 2.18 KB
/
single-note.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<?php
/**
* The template for displaying single Note entries.
*
* @package infectionNet
* @since infectionNet 0.1
*/
get_header();
?>
<div id="primary" class="site-content">
<div id="content" role="main">
<?php inet_breadcrumb(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<?php while ( have_posts() ) : the_post(); ?>
<header class="entry-header">
<div class="standardsub-left">
<div class="header-icon">
<img src="<?php bloginfo('template_url'); ?>/img/header-icon-notes.png" width="76" height="76" alt="" />
</div>
</div>
<div class="standardsub-right" style="background:url(<?php bloginfo('template_url'); ?>/img/header-image-clinical-resources.jpg) top left no-repeat;">
<h1 class="entry-title"><?php the_title(); ?></h1>
</div>
</header>
<div class="entry-content">
<div class="entry-content-right">
<?php the_content(); ?>
<div class="taxonomies">
<?php inet_tax_terms_singular(); ?>
</div>
</div><!--.entry-content-right-->
<div class="entry-content-left">
<?php
$categories = wp_get_post_terms(get_the_ID(), 'note_type');
if($categories):
$category = $categories[0];
?>
<p>Category: <a href="<?php echo get_term_link($category); ?>"><?php echo $category->name; ?></a></p>
<?php
endif;
?>
<h2>Other Notes</h2>
<?php
$categories = get_categories(
array (
'type' => 'note',
'taxonomy' => 'note_type',
'hierarchical' => 0
)
);
?>
<ul class="links-list">
<?php
foreach ($categories as $cat):
?>
<li><a href="<?php echo get_term_link($cat); ?>"><?php echo $cat->name; ?></a></li>
<?php
endforeach;
?>
</ul>
<?php inet_related_content('h2', 'Related Content'); ?>
</div><!--.entry-content-left-->
</div><!-- .entry-content -->
<footer class="entry-meta">
<?php edit_post_link( __( 'Edit', 'inet' ), '<p class="edit-link">', '</p>' ); ?>
</footer><!-- .entry-meta -->
<?php endwhile; // end of the loop. ?>
</article><!-- #post -->
</div><!-- #content -->
</div><!-- #primary -->
<?php
get_footer();
?>