-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtpm_page_category_items.tpl.php
More file actions
executable file
·84 lines (68 loc) · 2.85 KB
/
tpm_page_category_items.tpl.php
File metadata and controls
executable file
·84 lines (68 loc) · 2.85 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<?php include('includes/getMarketplaceCategorySearch.inc.php');?>
<!-- The shortcode for this page is [tpm-marketplace-categories] -->
<?php if (isset($category_items) AND !empty($category_items)): ?>
<!-- Let's add the search box -->
<?php include('tpm_widget_search_box.tpl.php');?>
<div class="tpm-page-wrapper">
<!-- Let's add the category widget -->
<?php include('tpm_widget_category.tpl.php');?>
<div class="tpm-dotted"> </div>
<div id="tpm-paging" class="container">
<div class="content clearfix">
<?php foreach($category_items as $category_item) : ?>
<div id="tooltip_<?php echo $category_item->item_id; ?>" class="tpm-item tooltip">
<div class="item-inner">
<div class="image">
<a href="<?php echo bloginfo('url'); ?>/<?php echo TPM_PATH_MARKETPLACE; ?>/<?php echo TPM_PATH_ITEM; ?>/?item=<?php echo $category_item->item_id; ?>">
<?php if (isset($category_item->image->xsmall)): ?>
<img src="<?php echo $category_item->image->xsmall; ?>"/>
<?php endif; ?>
</a>
</div>
<div class="tpm-title">
<?php echo truncate($category_item->title,24); ?>
</div>
<div class="price">
<span class="price <?php echo $category_item->currency; ?>"><?php echo $category_item->price; ?></span>
</div>
<div class="tpm-meta-name">
by <a href="<?php echo bloginfo('url'); ?>/<?php echo TPM_PATH_MARKETPLACE; ?>/<?php echo TPM_PATH_SELLER; ?>/?seller=<?php echo $category_item->user_id; ?>">
<?php echo $category_item->user_name; ?>
</a>
</div>
</div>
<!-- Data for the tooltip -->
<div id="data_tooltip_<?php echo $category_item->item_id; ?>" class="hidden">
<div class="tooltip-inner">
<div class="tooltip-description">
<div class="tooltip-title"><?php echo $category_item->title; ?></div>
<?php echo truncate( $category_item->description,130);?>
</div>
<div class="tooltip-seller">
<div class="tooltip-subtitle">
</div>
<img src="<?php echo $category_item->user->avatar; ?>"/>
<div class="tooltip-subtitle">by <?php echo $category_item->user_name; ?></div>
</div>
</div>
</div>
</div>
<?php endforeach;?>
</div>
<div class="tpm-dotted"> </div>
<!-- Only show navigation if needed -->
<?php if (count($category_items)>12): ?>
<div class="page_navigation clearfix"></div>
<?php endif; ?>
</div>
</div>
<div class="tpm-meta-name float-right">powered by <a href="http://tinypay.me">Tinypay.me</a></div>
<?php else:
$options = get_option('tinypay_advanced_settings');
if(isset ($options['api_error']) AND !empty($options['api_error'])){
echo '<div class="tmp_message">'.$options['api_error'].'</div>';
} else{
echo '';
}
?>
<?php endif; ?>