From 9f020573748af28cc09cbde18e96cfc68641ce7b Mon Sep 17 00:00:00 2001 From: Friendika Date: Wed, 16 Feb 2011 02:07:11 -0800 Subject: provide permalink for posts, include permalinks in feeds and imported from feeds --- boot.php | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'boot.php') diff --git a/boot.php b/boot.php index 3dff39a33..dcf5b1c1a 100644 --- a/boot.php +++ b/boot.php @@ -2449,3 +2449,11 @@ function feed_salmonlinks($nick) { return $salmon; }} +if(! function_exists('get_plink')) { +function get_plink($item) { + $a = get_app(); + $plink = (((x($item,'plink')) && (! $item['private'])) ? '' : ''); + return $plink; +}} + -- cgit v1.2.3 From 527e050ecc1037973595fd5de12682cfa9e19d64 Mon Sep 17 00:00:00 2001 From: Friendika Date: Wed, 16 Feb 2011 17:32:15 -0800 Subject: sanitise all incoming url's - also stop them from getting mangled by simplepie --- boot.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'boot.php') diff --git a/boot.php b/boot.php index dcf5b1c1a..322a4e307 100644 --- a/boot.php +++ b/boot.php @@ -2453,7 +2453,12 @@ if(! function_exists('get_plink')) { function get_plink($item) { $a = get_app(); $plink = (((x($item,'plink')) && (! $item['private'])) ? '' : ''); + . $item['plink'] . '" title="' . t('link to source') . '">' . t('link to source') . '' : ''); return $plink; }} +if(! function_exists('unamp')) { +function unamp($s) { + return str_replace('&', '&', $s); +}} + -- cgit v1.2.3