Version Description
(future) = * Provide post url in success email
Download this release
Release Info
Developer | WayneAllen |
Plugin | Postie |
Version | 1.6.4 |
Comparing to | |
See all releases |
Code changes from version 1.6.3 to 1.6.4
- docs/Changes.txt +3 -0
- docs/Installation.txt +3 -3
- docs/Postie.txt +1 -1
- postie-functions.php +13 -8
- postie.php +3 -3
- readme.txt +7 -4
docs/Changes.txt
CHANGED
@@ -27,6 +27,9 @@ All script, style and body tags are stripped from html emails.
|
|
27 |
Attachments are now processed in the order they were attached.
|
28 |
|
29 |
== CHANGELOG ==
|
|
|
|
|
|
|
30 |
= 1.6.3 (2014.10.03) =
|
31 |
* Added postie_filter_email2 filter which includes To and Reply-To headers
|
32 |
* Added postie_author filter
|
27 |
Attachments are now processed in the order they were attached.
|
28 |
|
29 |
== CHANGELOG ==
|
30 |
+
= 1.6.4 (2014.10.21) =
|
31 |
+
* Provide post url in success email
|
32 |
+
|
33 |
= 1.6.3 (2014.10.03) =
|
34 |
* Added postie_filter_email2 filter which includes To and Reply-To headers
|
35 |
* Added postie_author filter
|
docs/Installation.txt
CHANGED
@@ -1,12 +1,12 @@
|
|
1 |
== Installation ==
|
2 |
* Either:
|
3 |
* Put the postie.zip file in wp-content/plugins/ and unzip it
|
|
|
|
|
4 |
* Or:
|
5 |
* Use the automatic installer (WP 2.7+)
|
6 |
* Login to WordPress as an administrator
|
7 |
-
*
|
8 |
-
* Activate "Postie"
|
9 |
-
* Goto to the "Settings" tab and click on the sub-tab "Postie" to configure it.
|
10 |
* Make sure you enter the mailserver information correctly, including the type
|
11 |
of connection and the port number. Common port configurations:
|
12 |
* (Postie ignores the settings under Settings->Writing->Writing-by-Email)
|
1 |
== Installation ==
|
2 |
* Either:
|
3 |
* Put the postie.zip file in wp-content/plugins/ and unzip it
|
4 |
+
* Goto the Plugins tab in the WordPress Admin Site
|
5 |
+
* Activate "Postie"
|
6 |
* Or:
|
7 |
* Use the automatic installer (WP 2.7+)
|
8 |
* Login to WordPress as an administrator
|
9 |
+
* Click "Postie" on the lefthand menu to configure it.
|
|
|
|
|
10 |
* Make sure you enter the mailserver information correctly, including the type
|
11 |
of connection and the port number. Common port configurations:
|
12 |
* (Postie ignores the settings under Settings->Writing->Writing-by-Email)
|
docs/Postie.txt
CHANGED
@@ -6,7 +6,7 @@ Plugin URI: http://PostiePlugin.com/
|
|
6 |
Tags: e-mail, email, post-by-email
|
7 |
Requires at least: 3.0
|
8 |
Tested up to: 4.0
|
9 |
-
Stable tag: 1.6.
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
6 |
Tags: e-mail, email, post-by-email
|
7 |
Requires at least: 3.0
|
8 |
Tested up to: 4.0
|
9 |
+
Stable tag: 1.6.4
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
postie-functions.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
-
$Id: postie-functions.php
|
4 |
*/
|
5 |
|
6 |
//to turn on debug output add the following line to wp-config.php
|
@@ -454,7 +454,7 @@ function PostEmail($poster, $mimeDecodedEmail, $config) {
|
|
454 |
} else {
|
455 |
DisplayEmailPost($details);
|
456 |
|
457 |
-
PostToDB($details, $is_reply, $custom_image_field, $postmodifiers);
|
458 |
|
459 |
if ($confirmation_email != '') {
|
460 |
if ($confirmation_email == 'sender') {
|
@@ -464,7 +464,7 @@ function PostEmail($poster, $mimeDecodedEmail, $config) {
|
|
464 |
} elseif ($confirmation_email == 'both') {
|
465 |
$recipients = array($details['email_author'], get_option("admin_email"));
|
466 |
}
|
467 |
-
MailToRecipients($mimeDecodedEmail, false, $recipients, false, false);
|
468 |
}
|
469 |
}
|
470 |
postie_disable_revisions(true);
|
@@ -887,7 +887,7 @@ function POP3MessageFetch($server = NULL, $port = NULL, $email = NULL, $password
|
|
887 |
* @param array - details of the post
|
888 |
*/
|
889 |
function PostToDB($details, $isReply, $customImageField, $postmodifiers) {
|
890 |
-
|
891 |
if (!$isReply) {
|
892 |
$post_ID = wp_insert_post($details, true);
|
893 |
if (is_wp_error($post_ID)) {
|
@@ -934,6 +934,7 @@ function PostToDB($details, $isReply, $customImageField, $postmodifiers) {
|
|
934 |
|
935 |
do_action('postie_post_after', $details);
|
936 |
}
|
|
|
937 |
}
|
938 |
|
939 |
/**
|
@@ -1394,7 +1395,7 @@ function ValidatePoster(&$mimeDecodedEmail, $config) {
|
|
1394 |
if ($user->has_cap("post_via_postie")) {
|
1395 |
DebugEcho("$user_ID has 'post_via_postie' permissions");
|
1396 |
$poster = $user_ID;
|
1397 |
-
|
1398 |
DebugEcho("ValidatePoster: pre postie_author $poster");
|
1399 |
$poster = apply_filters("postie_author", $poster);
|
1400 |
DebugEcho("ValidatePoster: post postie_author $poster");
|
@@ -2058,7 +2059,7 @@ function filter_PreferedText($mimeDecodedEmail, $preferTextType) {
|
|
2058 |
* This function can be used to send confirmation or rejection emails
|
2059 |
* It accepts an object containing the entire message
|
2060 |
*/
|
2061 |
-
function MailToRecipients(&$mail_content, $testEmail = false, $recipients = array(), $returnToSender, $reject = true) {
|
2062 |
DebugEcho("MailToRecipients: send mail");
|
2063 |
if ($testEmail) {
|
2064 |
return false;
|
@@ -2068,6 +2069,10 @@ function MailToRecipients(&$mail_content, $testEmail = false, $recipients = arra
|
|
2068 |
$myemailadd = get_option("admin_email");
|
2069 |
$blogname = get_option("blogname");
|
2070 |
$blogurl = get_option("siteurl");
|
|
|
|
|
|
|
|
|
2071 |
|
2072 |
if (count($recipients) == 0) {
|
2073 |
DebugEcho("MailToRecipients: no recipients");
|
@@ -2132,8 +2137,8 @@ function MailToRecipients(&$mail_content, $testEmail = false, $recipients = arra
|
|
2132 |
}
|
2133 |
} else {
|
2134 |
$alert_subject = "Successfully posted to $blogname";
|
2135 |
-
|
2136 |
-
|
2137 |
}
|
2138 |
|
2139 |
wp_mail($myemailadd, $alert_subject, $mailtext, $headers);
|
1 |
<?php
|
2 |
/*
|
3 |
+
$Id: postie-functions.php 1011691 2014-10-21 19:08:46Z WayneAllen $
|
4 |
*/
|
5 |
|
6 |
//to turn on debug output add the following line to wp-config.php
|
454 |
} else {
|
455 |
DisplayEmailPost($details);
|
456 |
|
457 |
+
$postid = PostToDB($details, $is_reply, $custom_image_field, $postmodifiers);
|
458 |
|
459 |
if ($confirmation_email != '') {
|
460 |
if ($confirmation_email == 'sender') {
|
464 |
} elseif ($confirmation_email == 'both') {
|
465 |
$recipients = array($details['email_author'], get_option("admin_email"));
|
466 |
}
|
467 |
+
MailToRecipients($mimeDecodedEmail, false, $recipients, false, false, $postid);
|
468 |
}
|
469 |
}
|
470 |
postie_disable_revisions(true);
|
887 |
* @param array - details of the post
|
888 |
*/
|
889 |
function PostToDB($details, $isReply, $customImageField, $postmodifiers) {
|
890 |
+
$post_ID = 0;
|
891 |
if (!$isReply) {
|
892 |
$post_ID = wp_insert_post($details, true);
|
893 |
if (is_wp_error($post_ID)) {
|
934 |
|
935 |
do_action('postie_post_after', $details);
|
936 |
}
|
937 |
+
return $post_ID;
|
938 |
}
|
939 |
|
940 |
/**
|
1395 |
if ($user->has_cap("post_via_postie")) {
|
1396 |
DebugEcho("$user_ID has 'post_via_postie' permissions");
|
1397 |
$poster = $user_ID;
|
1398 |
+
|
1399 |
DebugEcho("ValidatePoster: pre postie_author $poster");
|
1400 |
$poster = apply_filters("postie_author", $poster);
|
1401 |
DebugEcho("ValidatePoster: post postie_author $poster");
|
2059 |
* This function can be used to send confirmation or rejection emails
|
2060 |
* It accepts an object containing the entire message
|
2061 |
*/
|
2062 |
+
function MailToRecipients(&$mail_content, $testEmail = false, $recipients = array(), $returnToSender, $reject = true, $postid = null) {
|
2063 |
DebugEcho("MailToRecipients: send mail");
|
2064 |
if ($testEmail) {
|
2065 |
return false;
|
2069 |
$myemailadd = get_option("admin_email");
|
2070 |
$blogname = get_option("blogname");
|
2071 |
$blogurl = get_option("siteurl");
|
2072 |
+
$posturl = '';
|
2073 |
+
if ($postid != null) {
|
2074 |
+
$posturl = get_permalink($postid);
|
2075 |
+
}
|
2076 |
|
2077 |
if (count($recipients) == 0) {
|
2078 |
DebugEcho("MailToRecipients: no recipients");
|
2137 |
}
|
2138 |
} else {
|
2139 |
$alert_subject = "Successfully posted to $blogname";
|
2140 |
+
$mailtext = "Your post '$subject' has been successfully published to $blogname <$posturl>.\n";
|
2141 |
+
DebugEcho("MailToRecipients: $alert_subject\n$mailtext");
|
2142 |
}
|
2143 |
|
2144 |
wp_mail($myemailadd, $alert_subject, $mailtext, $headers);
|
postie.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
Plugin Name: Postie
|
5 |
Plugin URI: http://PostiePlugin.com/
|
6 |
Description: Create posts via email. Signifigantly upgrades the Post by Email features of Word Press.
|
7 |
-
Version: 1.6.
|
8 |
Author: Wayne Allen
|
9 |
Author URI: http://allens-home.com/
|
10 |
License: GPL2
|
@@ -27,11 +27,11 @@
|
|
27 |
*/
|
28 |
|
29 |
/*
|
30 |
-
$Id: postie.php
|
31 |
*/
|
32 |
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "postie-functions.php");
|
33 |
|
34 |
-
define('POSTIE_VERSION', '1.6.
|
35 |
define("POSTIE_ROOT", dirname(__FILE__));
|
36 |
define("POSTIE_URL", WP_PLUGIN_URL . '/' . basename(dirname(__FILE__)));
|
37 |
|
4 |
Plugin Name: Postie
|
5 |
Plugin URI: http://PostiePlugin.com/
|
6 |
Description: Create posts via email. Signifigantly upgrades the Post by Email features of Word Press.
|
7 |
+
Version: 1.6.4
|
8 |
Author: Wayne Allen
|
9 |
Author URI: http://allens-home.com/
|
10 |
License: GPL2
|
27 |
*/
|
28 |
|
29 |
/*
|
30 |
+
$Id: postie.php 1011696 2014-10-21 19:11:48Z WayneAllen $
|
31 |
*/
|
32 |
require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "postie-functions.php");
|
33 |
|
34 |
+
define('POSTIE_VERSION', '1.6.4');
|
35 |
define("POSTIE_ROOT", dirname(__FILE__));
|
36 |
define("POSTIE_URL", WP_PLUGIN_URL . '/' . basename(dirname(__FILE__)));
|
37 |
|
readme.txt
CHANGED
@@ -6,7 +6,7 @@ Plugin URI: http://PostiePlugin.com/
|
|
6 |
Tags: e-mail, email, post-by-email
|
7 |
Requires at least: 3.0
|
8 |
Tested up to: 4.0
|
9 |
-
Stable tag: 1.6.
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
@@ -58,12 +58,12 @@ More info at http://PostiePlugin.com/
|
|
58 |
== Installation ==
|
59 |
* Either:
|
60 |
* Put the postie.zip file in wp-content/plugins/ and unzip it
|
|
|
|
|
61 |
* Or:
|
62 |
* Use the automatic installer (WP 2.7+)
|
63 |
* Login to WordPress as an administrator
|
64 |
-
*
|
65 |
-
* Activate "Postie"
|
66 |
-
* Goto to the "Settings" tab and click on the sub-tab "Postie" to configure it.
|
67 |
* Make sure you enter the mailserver information correctly, including the type
|
68 |
of connection and the port number. Common port configurations:
|
69 |
* (Postie ignores the settings under Settings->Writing->Writing-by-Email)
|
@@ -238,6 +238,9 @@ All script, style and body tags are stripped from html emails.
|
|
238 |
Attachments are now processed in the order they were attached.
|
239 |
|
240 |
== CHANGELOG ==
|
|
|
|
|
|
|
241 |
= 1.6.3 (2014.10.03) =
|
242 |
* Added postie_filter_email2 filter which includes To and Reply-To headers
|
243 |
* Added postie_author filter
|
6 |
Tags: e-mail, email, post-by-email
|
7 |
Requires at least: 3.0
|
8 |
Tested up to: 4.0
|
9 |
+
Stable tag: 1.6.4
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
58 |
== Installation ==
|
59 |
* Either:
|
60 |
* Put the postie.zip file in wp-content/plugins/ and unzip it
|
61 |
+
* Goto the Plugins tab in the WordPress Admin Site
|
62 |
+
* Activate "Postie"
|
63 |
* Or:
|
64 |
* Use the automatic installer (WP 2.7+)
|
65 |
* Login to WordPress as an administrator
|
66 |
+
* Click "Postie" on the lefthand menu to configure it.
|
|
|
|
|
67 |
* Make sure you enter the mailserver information correctly, including the type
|
68 |
of connection and the port number. Common port configurations:
|
69 |
* (Postie ignores the settings under Settings->Writing->Writing-by-Email)
|
238 |
Attachments are now processed in the order they were attached.
|
239 |
|
240 |
== CHANGELOG ==
|
241 |
+
= 1.6.4 (future) =
|
242 |
+
* Provide post url in success email
|
243 |
+
|
244 |
= 1.6.3 (2014.10.03) =
|
245 |
* Added postie_filter_email2 filter which includes To and Reply-To headers
|
246 |
* Added postie_author filter
|