Bugfix in wppost, improvement in libertree export and changes in statusnet and twitter #62

Merged
annando merged 32 commits from master into master 2012-06-23 14:10:19 +02:00
Showing only changes of commit eeed84f200 - Show all commits

View file

@ -168,22 +168,31 @@ function tumblr_send(&$a,&$b) {
if(count($tag_arr))
$tags = implode(',',$tag_arr);
$link = "";
if ($b['title'] == '') {
// Take the description from the bookmark
if(preg_match("/\[bookmark\=([^\]]*)\](.*?)\[\/bookmark\]/is",$b['body'],$matches))
$b['title'] = $matches[2];
$link = $matches[1];
$b['title'] = html_entity_decode($matches[2],ENT_QUOTES,'UTF-8');
}
$params = array(
'email' => $tmbl_username,
'password' => $tmbl_password,
'title' => $b['title'],
'type' => 'regular',
'format' => 'html',
'generator' => 'Friendica',
'tags' => $tags,
'body' => bbcode($b['body'])
);
'tags' => $tags);
if ($link != '') {
$params['type'] = "link";
$params['name'] = $b['title'],
$params['url'] = $link;
$params['description'] = bbcode($b['body']);
} else {
$params['type'] = "regular";
$params['title'] = $b['title'],
$params['body'] = bbcode($b['body']);
}
$x = post_url($tmbl_blog,$params);
$ret_code = $a->get_curl_code();