diff options
author | nodiscc <nodiscc@gmail.com> | 2014-10-20 19:14:52 +0200 |
---|---|---|
committer | nodiscc <nodiscc@gmail.com> | 2014-10-21 16:18:25 +0200 |
commit | 27646ca5b41bdf09bd73c0e05c352379214b0011 (patch) | |
tree | e0b3f72754f64eff9043a8de9a578840050fe747 /index.php | |
parent | c4a329ede2d19d3a9431334176d9bebf35d6bb96 (diff) | |
download | Shaarli-27646ca5b41bdf09bd73c0e05c352379214b0011.tar.gz Shaarli-27646ca5b41bdf09bd73c0e05c352379214b0011.tar.zst Shaarli-27646ca5b41bdf09bd73c0e05c352379214b0011.zip |
add link: in case of empty URL (self-post), prepend "Note: " to the title
* Thanks to qwertygc (https://github.com/shaarli/Shaarli/pull/23)
* Fix small typo
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -1587,7 +1587,11 @@ function renderPage() | |||
1587 | } | 1587 | } |
1588 | } | 1588 | } |
1589 | } | 1589 | } |
1590 | if ($url=='') $url='?'.smallHash($linkdate); // In case of empty URL, this is just a text (with a link that point to itself) | 1590 | if ($url=='') // In case of empty URL, this is just a text (with a link that points to itself) |
1591 | { | ||
1592 | $url='?'.smallHash($linkdate); | ||
1593 | $title='Note: '; | ||
1594 | } | ||
1591 | $link = array('linkdate'=>$linkdate,'title'=>$title,'url'=>$url,'description'=>$description,'tags'=>$tags,'private'=>$private); | 1595 | $link = array('linkdate'=>$linkdate,'title'=>$title,'url'=>$url,'description'=>$description,'tags'=>$tags,'private'=>$private); |
1592 | } | 1596 | } |
1593 | 1597 | ||