]> git.immae.eu Git - github/shaarli/Shaarli.git/blame - tpl/linklist.html
Cleanup: explicitely loop over PHP variables in templates
[github/shaarli/Shaarli.git] / tpl / linklist.html
CommitLineData
45034273
SS
1<!DOCTYPE html>
2<html>
65d62517
A
3<head>
4 <link type="text/css" rel="stylesheet" href="../inc/awesomplete.css" />
5 {include="includes"}
6</head>
45034273
SS
7<body>
8<div id="pageheader">
af77b2fd 9 {include="page.header"}
822bffce 10
c133612f 11 <div id="headerform" class="search">
0923a2bc 12 <form method="GET" class="searchform" name="searchform">
822bffce 13 <input type="text" tabindex="1" id="searchform_value" name="searchterm" placeholder="Search text"
c51fae92
A
14 {if="!empty($search_term)"}
15 value="{$search_term}"
822bffce
A
16 {/if}
17 >
b39b1bc2
A
18 <input type="submit" value="Search" class="bigbutton">
19 </form>
65d62517 20 <form method="GET" class="tagfilter" name="tagfilter">
822bffce 21 <input type="text" tabindex="2" name="searchtags" id="tagfilter_value" placeholder="Filter by tag"
c51fae92
A
22 {if="!empty($search_tags)"}
23 value="{$search_tags}"
822bffce
A
24 {/if}
25 autocomplete="off" class="awesomplete" data-multiple data-minChars="1"
55d0a5c4 26 data-list="{loop="$tags"}{$key}, {/loop}"
822bffce 27 >
65d62517
A
28 <input type="submit" value="Search" class="bigbutton">
29 </form>
567967fd
A
30 {loop="$plugins_header.fields_toolbar"}
31 {$value}
32 {/loop}
af77b2fd 33 </div>
45034273
SS
34</div>
35
36<div id="linklist">
37
38 {include="linklist.paging"}
39
567967fd
A
40 <div id="plugin_zone_start_linklist" class="plugin_zone">
41 {loop="$plugin_start_zone"}
42 {$value}
43 {/loop}
44 </div>
45
45034273 46 {if="count($links)==0"}
c51fae92
A
47 <div id="searchcriteria">Nothing found.</div>
48 {elseif="!empty($search_term) or !empty($search_tags)"}
49 <div id="searchcriteria">
50 {$result_count} results
51 {if="!empty($search_term)"}
52 for <em>{$search_term}</em>
53 {/if}
54 {if="!empty($search_tags)"}
55 {$exploded_tags=explode(' ', $search_tags)}
56 tagged
57 {loop="$exploded_tags"}
58 <span class="linktag" title="Remove tag">
59 <a href="?removetag={function="urlencode($value)"}">{$value} <span class="remove">x</span></a>
60 </span>
61 {/loop}
62 {/if}
63 </div>
45034273
SS
64 {/if}
65 <ul>
dec5fe9c 66 {loop="$links"}
45034273 67 <li{if="$value.class"} class="{$value.class}"{/if}>
567967fd 68 <a id="{$value.shorturl}"></a>
45034273
SS
69 <div class="thumbnail">{$value.url|thumbnail}</div>
70 <div class="linkcontainer">
45034273 71 {if="isLoggedIn()"}
b2877611 72 <div class="linkeditbuttons">
b39b1bc2
A
73 <form method="GET" class="buttoneditform">
74 <input type="hidden" name="edit_link" value="{$value.linkdate}">
75 <input type="image" alt="Edit" src="images/edit_icon.png#" title="Edit" class="button_edit">
76 </form><br>
77 <form method="POST" class="buttoneditform">
78 <input type="hidden" name="lf_linkdate" value="{$value.linkdate}">
79 <input type="hidden" name="token" value="{$token}">
80 <input type="hidden" name="delete_link">
81 <input type="image" alt="Delete" src="images/delete_icon.png#" title="Delete"
82 class="button_delete" onClick="return confirmDeleteLink();">
83 </form>
b2877611 84 </div>
45034273 85 {/if}
90e5bd65
A
86 <span class="linktitle">
87 <a href="{$value.real_url}">{$value.title}</a>
88 </span>
45034273 89 <br>
c133612f 90 {if="$value.description"}<div class="linkdescription">{$value.description}</div>{/if}
b74b96bf 91 {if="!$hide_timestamps || isLoggedIn()"}
9646b7da
A
92 {$updated=$value.updated_timestamp ? 'Edited: '. strftime('%c', $value.updated_timestamp) : 'Permalink'}
93 <span class="linkdate" title="Permalink">
94 <a href="?{$value.linkdate|smallHash}">
95 <span title="{$updated}">
96 {function="strftime('%c', $value.timestamp)"}
97 {if="$value.updated_timestamp"}*{/if}
98 </span>
99 - permalink
100 </a> -
101 </span>
45034273 102 {else}
567967fd 103 <span class="linkdate" title="Short link here"><a href="?{$value.shorturl}">permalink</a> - </span>
45034273 104 {/if}
567967fd
A
105
106 {loop="$value.link_plugin"}
107 <span>{$value}</span> -
108 {/loop}
109
90e5bd65 110 <a href="{$value.real_url}"><span class="linkurl" title="Short link">{$value.url}</span></a><br>
45034273
SS
111 {if="$value.tags"}
112 <div class="linktaglist">
dec5fe9c 113 {loop="$value.taglist"}<span class="linktag" title="Add tag"><a href="?addtag={$value|urlencode}">{$value}</a></span> {/loop}
45034273
SS
114 </div>
115 {/if}
567967fd
A
116
117
45034273
SS
118 </div>
119 </li>
120 {/loop}
121 </ul>
122
567967fd
A
123 <div id="plugin_zone_end_linklist" class="plugin_zone">
124 {loop="$plugin_end_zone"}
125 {$value}
126 {/loop}
127 </div>
128
45034273
SS
129 {include="linklist.paging"}
130
131</div>
132
d741c9fc 133 {include="page.footer"}
af77b2fd 134
65d62517 135<script src="inc/awesomplete.min.js#"></script>
b39b1bc2
A
136<script src="inc/awesomplete-multiple-tags.js#"></script>
137<script>
138 awesompleteUniqueTag('#tagfilter_value');
139</script>
45034273 140</body>
af77b2fd 141</html>