-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathindex.php
More file actions
67 lines (59 loc) · 2.54 KB
/
index.php
File metadata and controls
67 lines (59 loc) · 2.54 KB
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
<?php
$pageTitle = get_theme_option('Homepage Title');
if (!isset($pageTitle) || $pageTitle == '') {
$pageTitle = sprintf(__('Welcome to %s'), option('site_title'));
}
$backgroundColor = ((get_theme_option('homepage_background_color') !== null) && (get_theme_option('homepage_background_color') !== '')) ? get_theme_option('homepage_background_color') : 'FFFFFF';
$backgroundImage = ((get_theme_option('homepage_background') !== null) && get_theme_option('homepage_background') !== '') ? "url('" . foundation_homepage_intro_background() . "')" : '';
queue_css_string("#intro { background: center/cover $backgroundImage $backgroundColor; }");
?>
<?php echo head(array('bodyid' => 'home')); ?>
<div id="intro">
<h1><?php echo $pageTitle; ?></h1>
<?php echo get_theme_option('Homepage Text'); ?>
</div>
<div class="featured-records">
<?php $featuredRecordHtml = foundation_get_featured_records(); ?>
<!-- Featured Collection -->
<div class="main featured">
<?php echo $featuredRecordHtml[0]; ?>
</div><!-- end featured collection -->
<div class="supporting featured">
<?php echo $featuredRecordHtml[1]; ?>
<?php echo $featuredRecordHtml[2]; ?>
</div>
</div>
<hr>
<?php
$recentItems = get_theme_option('Homepage Recent Items');
if ($recentItems === null || $recentItems === ''):
$recentItems = 6;
else:
$recentItems = (int) $recentItems;
endif;
if ($recentItems):
?>
<div class="supporting-content">
<h2 class="text-center"><?php echo __('Recently Added Items'); ?></h2>
<hr>
<div class="recent-items">
<?php echo recent_items($recentItems); ?>
<p class="view-items-link"><a href="<?php echo html_escape(url('items')); ?>"><?php echo __('View All Items'); ?></a></p>
</div>
<div class="other">
<div class="item total">
<span class="count"><?php echo total_records('item'); ?></span> <?php echo __('items'); ?>
</div>
<div class="collection total">
<span class="count"><?php echo total_records('collections'); ?></span> <?php echo __('collections'); ?>
</div>
<?php if (plugin_is_active('ExhibitBuilder')): ?>
<div class="exhibit total">
<span class="count"><?php echo total_records('exhibits'); ?></span> <?php echo __('exhibits'); ?>
</div>
<?php endif; ?>
</div>
</div><!--end recent-items -->
<?php endif; ?>
<?php fire_plugin_hook('public_home', array('view' => $this)); ?>
<?php echo foot(); ?>