Postie - Version 1.8.20

Version Description

(2016-11-21) = * Fix issue where attachment with Content-ID doesn't have a reference in the html not being added to the post.

Download this release

Release Info

Developer WayneAllen
Plugin Icon 128x128 Postie
Version 1.8.20
Comparing to
See all releases

Code changes from version 1.8.19 to 1.8.20

Files changed (5) hide show
  1. docs/Changes.txt +3 -0
  2. docs/Postie.txt +1 -1
  3. postie-functions.php +19 -22
  4. postie.php +3 -3
  5. readme.txt +4 -1
docs/Changes.txt CHANGED
@@ -32,6 +32,9 @@ All script, style and body tags are stripped from html emails.
32
  Attachments are now processed in the order they were attached.
33
 
34
  == CHANGELOG ==
 
 
 
35
  = 1.8.19 (2016-11-16) =
36
  * Fix issue where attachments not showing if both plain and html are blank and the attachment is part of a multipart (related) block.
37
 
32
  Attachments are now processed in the order they were attached.
33
 
34
  == CHANGELOG ==
35
+ = 1.8.20 (2016-11-21) =
36
+ * Fix issue where attachment with Content-ID doesn't have a reference in the html not being added to the post.
37
+
38
  = 1.8.19 (2016-11-16) =
39
  * Fix issue where attachments not showing if both plain and html are blank and the attachment is part of a multipart (related) block.
40
 
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.3.0
8
  Tested up to: 4.6.1
9
- Stable tag: 1.8.19
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.3.0
8
  Tested up to: 4.6.1
9
+ Stable tag: 1.8.20
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 1535894 2016-11-17 21:01:46Z WayneAllen $
4
  */
5
 
6
  class PostiePostModifiers {
@@ -236,31 +236,27 @@ function filter_AttachmentTemplates($content, $mimeDecodedEmail, $post_id, $conf
236
  }
237
  }
238
 
239
- if ($config['prefer_text_type'] == 'plain') {
240
- DebugEcho("filter_AttachmentTemplates: # inline: " . count($mimeDecodedEmail['inline']));
241
- DebugEcho("filter_AttachmentTemplates: # related: " . count($mimeDecodedEmail['related']));
242
- foreach (array_merge($mimeDecodedEmail['inline'], $mimeDecodedEmail['related']) as $attachment) {
243
- DebugEcho("filter_AttachmentTemplates: image: " . $attachment['wp_filename']);
244
- $skip = ($fiid == $attachment['wp_id'] && !$config['include_featured_image']) || $attachment['exclude'];
245
- if (!$skip) {
246
- if (!$addimages && $attachment['primary'] == 'image') {
247
- DebugEcho("filter_AttachmentTemplates: skip image (alt) " . $attachment['wp_filename']);
 
 
 
248
  } else {
249
- $template = $attachment['template'];
250
- if ($config['images_append']) {
251
- $template = apply_filters('postie_place_media_after', $template, $attachment['wp_id']);
252
- } else {
253
- $template = apply_filters('postie_place_media_before', $template, $attachment['wp_id']);
254
- }
255
- DebugEcho("filter_AttachmentTemplates: post filter (alt) '$template'");
256
- $html .= $template;
257
  }
258
- } else {
259
- DebugEcho("filter_AttachmentTemplates: skip attachment (alt) " . $attachment['wp_filename']);
260
  }
 
 
261
  }
262
- } else {
263
- DebugEcho("filter_AttachmentTemplates: skipping inline and related");
264
  }
265
 
266
  if ($config['images_append']) {
@@ -326,6 +322,7 @@ function filter_AttachmentTemplates($content, $mimeDecodedEmail, $post_id, $conf
326
  }
327
 
328
  function postie_create_post($poster, $mimeDecodedEmail, $post_id, &$is_reply, $config, $postmodifiers) {
 
329
 
330
  $fulldebug = IsDebugMode();
331
  $fulldebugdump = false;
1
  <?php
2
  /*
3
+ $Id: postie-functions.php 1537852 2016-11-21 20:20:38Z WayneAllen $
4
  */
5
 
6
  class PostiePostModifiers {
236
  }
237
  }
238
 
239
+ DebugEcho("filter_AttachmentTemplates: # inline: " . count($mimeDecodedEmail['inline']));
240
+ DebugEcho("filter_AttachmentTemplates: # related: " . count($mimeDecodedEmail['related']));
241
+ foreach (array_merge($mimeDecodedEmail['inline'], $mimeDecodedEmail['related']) as $attachment) {
242
+ DebugEcho("filter_AttachmentTemplates: image: " . $attachment['wp_filename']);
243
+ $skip = ($fiid == $attachment['wp_id'] && !$config['include_featured_image']) || $attachment['exclude'];
244
+ if (!$skip) {
245
+ if (!$addimages && $attachment['primary'] == 'image') {
246
+ DebugEcho("filter_AttachmentTemplates: skip image (alt) " . $attachment['wp_filename']);
247
+ } else {
248
+ $template = $attachment['template'];
249
+ if ($config['images_append']) {
250
+ $template = apply_filters('postie_place_media_after', $template, $attachment['wp_id']);
251
  } else {
252
+ $template = apply_filters('postie_place_media_before', $template, $attachment['wp_id']);
 
 
 
 
 
 
 
253
  }
254
+ DebugEcho("filter_AttachmentTemplates: post filter (alt) '$template'");
255
+ $html .= $template;
256
  }
257
+ } else {
258
+ DebugEcho("filter_AttachmentTemplates: skip attachment (alt) " . $attachment['wp_filename']);
259
  }
 
 
260
  }
261
 
262
  if ($config['images_append']) {
322
  }
323
 
324
  function postie_create_post($poster, $mimeDecodedEmail, $post_id, &$is_reply, $config, $postmodifiers) {
325
+ DebugEcho("postie_create_post: prefer_text_type: " . $config['prefer_text_type']);
326
 
327
  $fulldebug = IsDebugMode();
328
  $fulldebugdump = false;
postie.php CHANGED
@@ -4,7 +4,7 @@
4
  Plugin Name: Postie
5
  Plugin URI: http://PostiePlugin.com/
6
  Description: Create posts via email. Significantly upgrades the Post by Email features of WordPress.
7
- Version: 1.8.19
8
  Author: Wayne Allen
9
  Author URI: http://PostiePlugin.com/
10
  License: GPL2
@@ -28,7 +28,7 @@
28
  */
29
 
30
  /*
31
- $Id: postie.php 1535895 2016-11-17 21:02:56Z WayneAllen $
32
  */
33
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib/fException.php");
34
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib/fUnexpectedException.php");
@@ -49,7 +49,7 @@ require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib/pPop3MailServer.php"
49
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib_autolink.php");
50
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "postie-functions.php");
51
 
52
- define('POSTIE_VERSION', '1.8.19');
53
  define("POSTIE_ROOT", dirname(__FILE__));
54
  define("POSTIE_URL", WP_PLUGIN_URL . '/' . basename(dirname(__FILE__)));
55
 
4
  Plugin Name: Postie
5
  Plugin URI: http://PostiePlugin.com/
6
  Description: Create posts via email. Significantly upgrades the Post by Email features of WordPress.
7
+ Version: 1.8.20
8
  Author: Wayne Allen
9
  Author URI: http://PostiePlugin.com/
10
  License: GPL2
28
  */
29
 
30
  /*
31
+ $Id: postie.php 1537856 2016-11-21 20:24:30Z WayneAllen $
32
  */
33
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib/fException.php");
34
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib/fUnexpectedException.php");
49
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "lib_autolink.php");
50
  require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . "postie-functions.php");
51
 
52
+ define('POSTIE_VERSION', '1.8.20');
53
  define("POSTIE_ROOT", dirname(__FILE__));
54
  define("POSTIE_URL", WP_PLUGIN_URL . '/' . basename(dirname(__FILE__)));
55
 
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.3.0
8
  Tested up to: 4.6.1
9
- Stable tag: 1.8.19
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -240,6 +240,9 @@ All script, style and body tags are stripped from html emails.
240
  Attachments are now processed in the order they were attached.
241
 
242
  == CHANGELOG ==
 
 
 
243
  = 1.8.19 (2016-11-16) =
244
  * Fix issue where attachments not showing if both plain and html are blank and the attachment is part of a multipart (related) block.
245
 
6
  Tags: e-mail, email, post-by-email
7
  Requires at least: 3.3.0
8
  Tested up to: 4.6.1
9
+ Stable tag: 1.8.20
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
240
  Attachments are now processed in the order they were attached.
241
 
242
  == CHANGELOG ==
243
+ = 1.8.20 (2016-11-21) =
244
+ * Fix issue where attachment with Content-ID doesn't have a reference in the html not being added to the post.
245
+
246
  = 1.8.19 (2016-11-16) =
247
  * Fix issue where attachments not showing if both plain and html are blank and the attachment is part of a multipart (related) block.
248