From f6556e0a720bb3de29107520464aa4de242e1631 Mon Sep 17 00:00:00 2001 From: Friendika Date: Sat, 25 Dec 2010 15:01:02 -0800 Subject: more plugin hooks --- mod/parse_url.php | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'mod/parse_url.php') diff --git a/mod/parse_url.php b/mod/parse_url.php index 1561eb8a3..b3b42b6cb 100644 --- a/mod/parse_url.php +++ b/mod/parse_url.php @@ -11,6 +11,16 @@ function parse_url_content(&$a) { $template = "%s%s"; + + $arr = array('url' => $url, 'text' => ''); + + call_hooks('parse_link', $arr); + + if(strlen($arr['text'])) { + echo $arr['text']; + killme(); + } + if($url) $s = fetch_url($url); else { @@ -18,6 +28,7 @@ function parse_url_content(&$a) { killme(); } + if(! $s) { echo sprintf($template,$url,$url,''); killme(); -- cgit v1.2.3