From c673c70c25143f18b2ef6aef9ee6633d0eac46ae Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 5 Aug 2012 21:41:58 -0700 Subject: updates --- mod/content.php | 1 + mod/editpost.php | 6 +++--- mod/parse_url.php | 8 +++++--- mod/photos.php | 1 + 4 files changed, 10 insertions(+), 6 deletions(-) (limited to 'mod') diff --git a/mod/content.php b/mod/content.php index 6e0e318b3..dc82b2b2f 100644 --- a/mod/content.php +++ b/mod/content.php @@ -697,6 +697,7 @@ function render_content(&$a, $items, $mode, $update, $preview = false) { '$edurl' => t('Link'), '$edvideo' => t('Video'), '$preview' => t('Preview'), + '$sourceapp' => t($a->sourcename), '$ww' => (($mode === 'network') ? $commentww : '') )); } diff --git a/mod/editpost.php b/mod/editpost.php index d7b0c39da..18b41a231 100644 --- a/mod/editpost.php +++ b/mod/editpost.php @@ -115,8 +115,8 @@ function editpost_content(&$a) { '$jotnets' => $jotnets, '$title' => $itm[0]['title'], '$placeholdertitle' => t('Set title'), - '$category' => file_tag_file_to_list($itm[0]['file'], 'category'), - '$placeholdercategory' => t('Categories (comma-separated list)'), + '$category' => file_tag_file_to_list($itm[0]['file'], 'category'), + '$placeholdercategory' => t('Categories (comma-separated list)'), '$emtitle' => t('Example: bob@example.com, mary@example.com'), '$lockstate' => $lockstate, '$acl' => '', // populate_acl((($group) ? $group_acl : $a->user), $celeb), @@ -124,7 +124,7 @@ function editpost_content(&$a) { '$profile_uid' => $_SESSION['uid'], '$preview' => t('Preview'), '$jotplugins' => $jotplugins, - '$mobileapp' => t('Friendica mobile web'), + '$sourceapp' => t($a->sourcename), )); return $o; diff --git a/mod/parse_url.php b/mod/parse_url.php index 5dd7de750..ea05055f0 100644 --- a/mod/parse_url.php +++ b/mod/parse_url.php @@ -176,6 +176,9 @@ function parseurl_getsiteinfo($url) { } } else { $src = completeurl($siteinfo["image"], $url); + + unset($siteinfo["image"]); + $photodata = getimagesize($src); if (($photodata[0] > 10) and ($photodata[1] > 10)) @@ -292,8 +295,7 @@ function parse_url_content(&$a) { $siteinfo = parseurl_getsiteinfo($url); if($siteinfo["title"] == "") { - echo print_r($siteinfo, true); - //echo sprintf($template,$url,$url,'') . $str_tags; + echo sprintf($template,$url,$url,'') . $str_tags; killme(); } else { $text = $siteinfo["text"]; @@ -302,7 +304,7 @@ function parse_url_content(&$a) { $image = ""; - if($siteinfo["image"] != ""){ + if(sizeof($siteinfo["images"]) > 0){ /* Execute below code only if image is present in siteinfo */ diff --git a/mod/photos.php b/mod/photos.php index 0354b1941..1a8d42143 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -1408,6 +1408,7 @@ function photos_content(&$a) { '$myphoto' => $contact['thumb'], '$comment' => t('Comment'), '$submit' => t('Submit'), + '$sourceapp' => t($a->sourcename), '$ww' => '' )); } -- cgit v1.2.3