-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
161 lines (132 loc) · 5.43 KB
/
index.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<?php head(array('bodyid'=>'home')); ?>
<div id="primary">
<!--About-->
<div id="site-description">
<h2>Om bildebasen</h2> <h3><?php echo settings('site_title'); ?></h3>
<?php echo deco_get_about(); ?>
<div id="hovedside_search" class="element">
<?php
if ($formActionUri):
$formAttributes['action'] = $formActionUri;
else:
$formAttributes['action'] = uri(array('controller'=>'items',
'action'=>'browse'));
endif;
$formAttributes['method'] = 'GET';
?>
<form <?php echo _tag_attributes($formAttributes); ?>>
<div id="search-keywords" class="field">
<div class="inputs">
<?php echo text(array(
'name' => 'search',
'size' => '40',
'id' => 'keyword-search',
'class' => 'textinput'), @$_REQUEST['search']);
?>
<input type="submit" class="submit" name="submit_search" id="submit_search_advanced" value="<?php echo __('Search'); ?>" />
</div>
</div>
</div>
<!--uncomment below to add an RSS feed to homepage or wait until next release
<h2>External Feed</h2>
<? //deco_display_rss('http://jeffersonsnewspaper.org/feed/',1);?>
-->
</div><!--end About-->
<!-- Featured Item -->
<!-- Start Awkward Gallery load/config -->
<script type="text/javascript">
jQuery.noConflict();
jQuery(document).ready(function()
{
jQuery("#showcase").awShowcase(
{
width: 625,
height: 500,
auto: true,
interval: 6500,
continuous: false,
loading: true,
tooltip_width: 200,
tooltip_icon_width: 32,
tooltip_icon_height: 32,
tooltip_offsetx: 18,
tooltip_offsety: 0,
arrows: false,
buttons: true,
btn_numbers: false,
keybord_keys: true,
mousetrace: false,
pauseonover: true,
transition: 'vslide', /* vslide/hslide/fade */
transition_speed: 500,
show_caption: 'onload', /* onload/onhover/show */
thumbnails: false,
thumbnails_position: 'outside-last', /* outside-last/outside-first/inside-last/inside-first */
thumbnails_direction: 'horizontal', /* vertical/horizontal */
thumbnails_slidex: 0 /* 0 = auto / 1 = slide one thumbnail / 2 = slide two thumbnails / etc. */
});
});
</script>
<!-- end Awkward Gallery load/config -->
<!-- Featured Items aka Awkward Showcase image gallery/slideshow-->
<h2 class="awkward">Utvalgte bilder fra basen</h2>
<div id="showcase" class="showcase">
<?php deco_awkward_gallery();?>
</div><!-- end featured items -->
<!-- Featured Exhibit -->
<!-- FIX Petter-->
<h2>Utvalgte bilder</h2>
<?php
$itemsf = deco_get_random_featured_items(9);
set_items_for_loop($itemsf);
while(loop_items()):
if (item_has_thumbnail($item)) {
$t = item('Dublin Core', 'Title');
$html .= link_to_item(item_square_thumbnail(array('class' =>'imagecoll', 'title'=>$t), 0, $item), array('class'=>'image'), 'show', $item);
}
endwhile;
echo $html; ?>
<!-- end featured collection -->
<!-- Featured Collection -->
<div id="featured-collection">
<?php echo deco_display_random_featured_collection();?>
</div><!-- end featured collection -->
</div><!-- end primary -->
<div id="secondary">
<!-- Recent Items -->
<div style="margin-bottom:30px">
<h2>Lokalhistoriske bildesamlinger</h2>
<h3><a href="/omeka/collections/show/2">Groruddalen</a></h3>
<h3><a href="/omeka/collections/show/3">Grefsen Kjelsås Nydalen</a></h3>
<h3><a href="/omeka/collections/show/7">Hellerud</a></h3>
<h3><a href="/omeka/collections/show/5">Sogn</a></h3>
<h3><a href="/omeka/collections/show/4">Søndre Aker</a></h3>
<h3><a href="/omeka/collections/show/6">Vindern</a></h3>
<h3><a href="/omeka/collections/show/1">Østensjø</a></h3>
</div>
<div id="recent-items">
<h2>Nye bilder</h2>
<?php
$deco_get_recent_number=deco_get_recent_number();
$items = get_items(array('recent'=>true, 'withImage'=>true), $deco_get_recent_number);?>
<?php set_items_for_loop($items); ?>
<?php if (has_items_for_loop()): ?>
<div class="items-list">
<?php while (loop_items()): ?>
<div class="item">
<h3><?php echo link_to_item(); ?></h3>
<?php if(item_has_thumbnail()): ?>
<div class="item-img">
<?php echo link_to_item(item_square_thumbnail()); ?>
</div>
<?php endif; ?>
</div>
<?php endwhile; ?>
</div>
<?php else: ?>
<p>No recent items available.</p>
<?php endif; ?>
<p class="view-items-link"><a href="<?php echo html_escape(uri('items')); ?>">Bla i alle bilder</a></p>
</div><!--end recent-items -->
</div><!-- end secondary -->
<?php foot(); ?>