aboutsummaryrefslogtreecommitdiffstats
path: root/util/wp
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-11-25 14:20:57 -0800
committerfriendica <info@friendica.com>2013-11-25 14:20:57 -0800
commitcbe096dd90292613e21725c8468eaf77f934d079 (patch)
tree05ac8669a05ec86c50d89f1dd29f68571a44224b /util/wp
parent41e9d0f0f90dc8cadc7d8fb101bc3f0b6cf17cc1 (diff)
downloadvolse-hubzilla-cbe096dd90292613e21725c8468eaf77f934d079.tar.gz
volse-hubzilla-cbe096dd90292613e21725c8468eaf77f934d079.tar.bz2
volse-hubzilla-cbe096dd90292613e21725c8468eaf77f934d079.zip
wp-to-red: now supports editing, titles, and native permalinks
Diffstat (limited to 'util/wp')
-rw-r--r--util/wp/post_to_red/post_to_red.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/util/wp/post_to_red/post_to_red.php b/util/wp/post_to_red/post_to_red.php
index 47af7789b..00c9b6b73 100644
--- a/util/wp/post_to_red/post_to_red.php
+++ b/util/wp/post_to_red/post_to_red.php
@@ -91,8 +91,6 @@ function post_to_red_post($post_id) {
$message = $post->post_title . "<br /><br />" . $message;
- $message .= "<br /><br />permalink: " . $post->guid;
-
if (isset($tag_string)) {
$message .= "<br />$tag_string";
}
@@ -104,7 +102,14 @@ function post_to_red_post($post_id) {
$headers = array('Authorization' => 'Basic '.base64_encode("$user_name:$password"));
- $body = array('status' => $bbcode,'source' => 'WordPress', 'namespace' => $message_namespace, 'remote_id' => $message_id);
+ $body = array(
+ 'title' => xpost_to_html2bbcode($post->post_title),
+ 'status' => $bbcode,
+ 'source' => 'WordPress',
+ 'namespace' => 'wordpress',
+ 'remote_id' => $message_id,
+ 'permalink' => $post->guid;
+ );
if($channel)
$body['channel'] = $channel;