aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornodiscc <nodiscc@gmail.com>2014-10-20 19:14:52 +0200
committernodiscc <nodiscc@gmail.com>2014-10-21 16:18:25 +0200
commit27646ca5b41bdf09bd73c0e05c352379214b0011 (patch)
treee0b3f72754f64eff9043a8de9a578840050fe747
parentc4a329ede2d19d3a9431334176d9bebf35d6bb96 (diff)
downloadShaarli-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
-rw-r--r--index.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/index.php b/index.php
index 294600d0..01872f4d 100644
--- a/index.php
+++ b/index.php
@@ -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