aboutsummaryrefslogtreecommitdiffhomepage
path: root/tpl/linklist.html
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2015-09-18 13:26:36 +0200
committerArthurHoaro <arthur@hoa.ro>2015-11-26 20:14:38 +0100
commit90e5bd65c9d4a5d3d5cedfeaa1314f2a15df5227 (patch)
tree7a085b9aecaa92aa5076df01df78c39edd2acff5 /tpl/linklist.html
parent986afb752bc57271e76935da9ed2df6ef8713cb7 (diff)
downloadShaarli-90e5bd65c9d4a5d3d5cedfeaa1314f2a15df5227.tar.gz
Shaarli-90e5bd65c9d4a5d3d5cedfeaa1314f2a15df5227.tar.zst
Shaarli-90e5bd65c9d4a5d3d5cedfeaa1314f2a15df5227.zip
URL encode links when a redirector is set.
Fixes #328 - URL encode links when a redirector is set * WARNING - template edit - new variable available : "real_url" Contains the final real url (redirected or any other change on original URL) * Don't redirect shaares link in RSS/Atom. * Affects links shaared in description. * Move text2clickable and keepMultipleSpaces to Utils.php + unit test UPDATE: * keepMultipleSpaces renamed to space2nbsp * space2nbsp improved to handle single space at line beginning * links in text description aren't 'nofollow' anymore
Diffstat (limited to 'tpl/linklist.html')
-rw-r--r--tpl/linklist.html6
1 files changed, 4 insertions, 2 deletions
diff --git a/tpl/linklist.html b/tpl/linklist.html
index f6e9e82b..666748a7 100644
--- a/tpl/linklist.html
+++ b/tpl/linklist.html
@@ -70,7 +70,9 @@
70 </form> 70 </form>
71 </div> 71 </div>
72 {/if} 72 {/if}
73 <span class="linktitle"><a href="{$redirector}{$value.url}">{$value.title}</a></span> 73 <span class="linktitle">
74 <a href="{$value.real_url}">{$value.title}</a>
75 </span>
74 <br> 76 <br>
75 {if="$value.description"}<div class="linkdescription">{$value.description}</div>{/if} 77 {if="$value.description"}<div class="linkdescription">{$value.description}</div>{/if}
76 {if="!$GLOBALS['config']['HIDE_TIMESTAMPS'] || isLoggedIn()"} 78 {if="!$GLOBALS['config']['HIDE_TIMESTAMPS'] || isLoggedIn()"}
@@ -83,7 +85,7 @@
83 <span>{$value}</span> - 85 <span>{$value}</span> -
84 {/loop} 86 {/loop}
85 87
86 <a href="{$value.url}"><span class="linkurl" title="Short link">{$value.url}</span></a><br> 88 <a href="{$value.real_url}"><span class="linkurl" title="Short link">{$value.url}</span></a><br>
87 {if="$value.tags"} 89 {if="$value.tags"}
88 <div class="linktaglist"> 90 <div class="linktaglist">
89 {loop="value.taglist"}<span class="linktag" title="Add tag"><a href="?addtag={$value|urlencode}">{$value}</a></span> {/loop} 91 {loop="value.taglist"}<span class="linktag" title="Add tag"><a href="?addtag={$value|urlencode}">{$value}</a></span> {/loop}