X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Foexchange.php;h=bbb436e7021ab3f0ad8088fedfde4772e46b0891;hb=724f9c80e79783957d75d011a0393f6d6bb1949e;hp=1e7c9b23c9e412427fc225d8ce2bd29acabfb770;hpb=0c67c89715df801e0c887be50c9739db3bae7ca3;p=friendica.git diff --git a/mod/oexchange.php b/mod/oexchange.php index 1e7c9b23c9..bbb436e702 100644 --- a/mod/oexchange.php +++ b/mod/oexchange.php @@ -1,6 +1,6 @@ argc > 1) && ($a->argv[1] === 'xrd')) { @@ -11,10 +11,9 @@ function oexchange_init(&$a) { killme(); } -} + } -if(! function_exists('oexchange_content')) { function oexchange_content(&$a) { if(! local_user()) { @@ -27,13 +26,13 @@ function oexchange_content(&$a) { return; } - $url = (((x($_REQUEST,'url')) && strlen($_REQUEST['url'])) + $url = (((x($_REQUEST,'url')) && strlen($_REQUEST['url'])) ? urlencode(notags(trim($_REQUEST['url']))) : ''); - $title = (((x($_REQUEST,'title')) && strlen($_REQUEST['title'])) + $title = (((x($_REQUEST,'title')) && strlen($_REQUEST['title'])) ? '&title=' . urlencode(notags(trim($_REQUEST['title']))) : ''); - $description = (((x($_REQUEST,'description')) && strlen($_REQUEST['description'])) + $description = (((x($_REQUEST,'description')) && strlen($_REQUEST['description'])) ? '&description=' . urlencode(notags(trim($_REQUEST['description']))) : ''); - $tags = (((x($_REQUEST,'tags')) && strlen($_REQUEST['tags'])) + $tags = (((x($_REQUEST,'tags')) && strlen($_REQUEST['tags'])) ? '&tags=' . urlencode(notags(trim($_REQUEST['tags']))) : ''); $s = fetch_url($a->get_baseurl() . '/parse_url?f=&url=' . $url . $title . $description . $tags); @@ -53,5 +52,7 @@ function oexchange_content(&$a) { $_REQUEST = $post; require_once('mod/item.php'); item_post($a); + } -} + +