-
Notifications
You must be signed in to change notification settings - Fork 0
/
node-library.tpl.php
100 lines (78 loc) · 2.74 KB
/
node-library.tpl.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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
<?php
// $Id$
/**
* @file
* Template to render library nodes.
*/
if ($page == 0) { ?>
<div id="node-<?php print $node->nid; ?>" class="<?php print $classes; ?> clearfix">
<div class="picture"><?php print $field_list_image[0]['view']; ?></div>
<div class="content">
<div class="library-openstatus <?php print $node->field_opening_hours_processed['status'];?>">
<?php print $node->field_opening_hours_processed['status_local'];?>
</div>
<div class="vcard">
<h2 class="fn org"><?php print l($node->title, 'node/'.$node->nid); ?></h2>
<div class="adr">
<div class="street-address"><?php print $node->location['street']; ?></div>
<span class="postal-code"><?php print $node->location['postal_code']; ?></span>
<span class="locality"><?php print $node->location['city']; ?></span>
</div>
<div class="link-card">
<a href="/biblioteker?lat=<?php echo $node->location['latitude'] ?>&long=<?php echo $node->location['longitude'] ?>" id="biblo-<?php print $node->nid ?>">Se på kort</a>
</div>
<?php if($node->location['phone']){ ?>
<div class="tel">
<span class="type"><?php print t('Phone'); ?>:</span> <span><?php print $node->location['phone']; ?></span>
</div>
<?php } ?>
<?php if($node->location['fax']){ ?>
<div class="tel">
<span class="type"><?php print t('Fax'); ?>:</span> <span><?php print $node->location['fax']; ?></span>
</div>
<?php } ?>
<?php if($node->field_email['0']['view']){ ?>
<div class="email">
<span class="type"><?php print t('E-mail'); ?>:</span> <span><?php print $node->field_email['0']['view']; ?></span>
</div>
<?php } ?>
<div class="geo">
<?php print t('Position'); ?>:
<span class="latitude"><?php echo $node->location['latitude'] ?></span>,
<span class="longitude"><?php echo $node->location['longitude'] ?></span>
</div>
</div>
</div>
<?php print $node->field_opening_hours['0']['view'];?>
</div>
<?php }else{
//Content
?>
<div id="node-<?php print $node->nid; ?>" class="<?php print $classes; ?> clearfix">
<h1><?php print $title;?></h1>
<div class="meta">
<?php if ($picture) { ;?>
<span class="author-picture">
<?php print $picture; ?>
</span>
<?php } ?>
<span class="time">
<?php print format_date($node->created, 'custom', "j F Y") ?>
</span>
<span class="author">
af <?php print theme('username', $node); ?>
</span>
<?php if (count($taxonomy)){ ?>
<div class="taxanomy">
<?php print $terms ?>
</div>
<?php } ?>
</div>
<div class="content">
<?php print $content ?>
</div>
<?php if ($links){ ?>
<?php print $links; ?>
<?php } ?>
</div>
<?php } ?>