Postie - Version 1.8.31

Version Description

(2017-02-07) = * Remove timezone warning if GMT+0 * Add postie_bare_link filter

Download this release

Release Info

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

Code changes from version 1.8.30 to 1.8.31

config_form_server.php CHANGED
@@ -59,12 +59,8 @@
59
  <td><input style="width: 70px;" name='postie-settings[time_offset]' type="number" step="0.5" id='postie-settings-time_offset' size="2" value="<?php echo esc_attr($time_offset); ?>" />
60
  <?php
61
  _e('hours', 'postie');
62
- $tz = get_option('timezone_string');
63
- if (empty($tz)) {
64
- ?><div class="notice notice-warning"><p>You have not set the blog time zone. You can do so on the <a href="<?php echo admin_url('options-general.php') ?>">General Settings page</a>. Note you may need to update the "Postie Time Correction" setting once you have done so.</p></div><?php
65
- }
66
  ?>
67
- <p class='description'><?php _e("Should be the same as your normal offset, but this lets you adjust it in cases where that doesn't work.", 'postie'); ?></p>
68
  </td>
69
  </tr>
70
  <tr>
59
  <td><input style="width: 70px;" name='postie-settings[time_offset]' type="number" step="0.5" id='postie-settings-time_offset' size="2" value="<?php echo esc_attr($time_offset); ?>" />
60
  <?php
61
  _e('hours', 'postie');
 
 
 
 
62
  ?>
63
+ <p class='description'><?php printf(__("Should be the same as your normal offset, but this lets you adjust it in cases where that doesn't work.<br>Blog timezone is: %s<br>Blog offset: %d", 'postie'), get_option('timezone_string') == '' ? 'GMT+0' : get_option('timezone_string'), get_option('gmt_offset')); ?></p>
64
  </td>
65
  </tr>
66
  <tr>
docs/Changes.txt CHANGED
@@ -35,6 +35,10 @@ All script, style and body tags are stripped from html emails.
35
  Attachments are now processed in the order they were attached.
36
 
37
  == CHANGELOG ==
 
 
 
 
38
  = 1.8.30 (2017-02-06) =
39
  * Fixed bug where Postie won't run on PHP versions prior to 5.5.
40
 
35
  Attachments are now processed in the order they were attached.
36
 
37
  == CHANGELOG ==
38
+ = 1.8.31 (2017-02-07) =
39
+ * Remove timezone warning if GMT+0
40
+ * Add postie_bare_link filter
41
+
42
  = 1.8.30 (2017-02-06) =
43
  * Fixed bug where Postie won't run on PHP versions prior to 5.5.
44
 
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.7.2
9
- Stable tag: 1.8.30
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.7.2
9
+ Stable tag: 1.8.31
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
lib_autolink.php CHANGED
@@ -171,9 +171,6 @@ class PostieAutolink {
171
  }
172
  }
173
 
174
- $link_url_enc = HtmlSpecialChars($link_url);
175
- $display_url_enc = HtmlSpecialChars($display_url);
176
-
177
  DebugEcho("autolink_do: link=$link_url");
178
 
179
  $skip = false;
@@ -189,12 +186,20 @@ class PostieAutolink {
189
  } else {
190
  DebugEcho("autolink_do: no oembed");
191
  }
 
 
 
 
192
  if ($skip) {
193
  DebugEcho("autolink_do: oembed source, skipping $link_url");
 
 
194
  $buffer .= $link_url_enc;
195
  } else {
196
  DebugEcho("autolink_do: linkifying $link_url");
197
- $buffer .= "<a href=\"{$link_url_enc}\"$currentTagfill>{$display_url_enc}</a>";
 
 
198
  }
199
  } else {
200
  //DebugEcho("autolink_do: fail 3 at $cursor");
@@ -358,7 +363,7 @@ class PostieAutolink {
358
 
359
  $cursor += strlen($pre) + strlen($hit);
360
  $buffer .= $pre;
361
- $buffer .= "<a href=\"mailto:$hit\"$tagfill>$hit</a>";
362
  }
363
  }
364
 
171
  }
172
  }
173
 
 
 
 
174
  DebugEcho("autolink_do: link=$link_url");
175
 
176
  $skip = false;
186
  } else {
187
  DebugEcho("autolink_do: no oembed");
188
  }
189
+
190
+ $link_url_enc = htmlspecialchars($link_url);
191
+ $display_url_enc = htmlspecialchars($display_url);
192
+
193
  if ($skip) {
194
  DebugEcho("autolink_do: oembed source, skipping $link_url");
195
+ $link_url_enc = apply_filters('postie_bare_link', $link_url_enc, $link_url, true);
196
+ DebugEcho("autolink_do: post postie_bare_link: $link_url_enc");
197
  $buffer .= $link_url_enc;
198
  } else {
199
  DebugEcho("autolink_do: linkifying $link_url");
200
+ $link_html = apply_filters('postie_bare_link', "<a href=\"{$link_url_enc}\"$currentTagfill>{$display_url_enc}</a>", $link_url, false);
201
+ DebugEcho("autolink_do: post postie_bare_link: $link_html");
202
+ $buffer .= $link_html;
203
  }
204
  } else {
205
  //DebugEcho("autolink_do: fail 3 at $cursor");
363
 
364
  $cursor += strlen($pre) + strlen($hit);
365
  $buffer .= $pre;
366
+ $buffer .= "<a href=\"mailto:$hit\" $tagfill>$hit</a>";
367
  }
368
  }
369
 
postie-functions.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- $Id: postie-functions.php 1590421 2017-02-07 03:29:06Z WayneAllen $
4
  */
5
 
6
  class PostiePostModifiers {
@@ -414,7 +414,7 @@ function postie_create_post($poster, $mimeDecodedEmail, $post_id, &$is_reply, $c
414
  }
415
 
416
  if ($config['converturls']) {
417
- $content = filter_Linkify($content, 'html' == $config['prefer_text_type']);
418
  if ($fulldebug) {
419
  DebugEcho("post linkify: $content");
420
  }
1
  <?php
2
  /*
3
+ $Id: postie-functions.php 1591296 2017-02-07 19:11:24Z WayneAllen $
4
  */
5
 
6
  class PostiePostModifiers {
414
  }
415
 
416
  if ($config['converturls']) {
417
+ $content = filter_Linkify($content);
418
  if ($fulldebug) {
419
  DebugEcho("post linkify: $content");
420
  }
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.30
8
  Author: Wayne Allen
9
  Author URI: http://PostiePlugin.com/
10
  License: GPL2
@@ -28,7 +28,7 @@
28
  */
29
 
30
  /*
31
- $Id: postie.php 1590422 2017-02-07 03:31:27Z 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.30');
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.31
8
  Author: Wayne Allen
9
  Author URI: http://PostiePlugin.com/
10
  License: GPL2
28
  */
29
 
30
  /*
31
+ $Id: postie.php 1591297 2017-02-07 19:13:24Z 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.31');
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.7.2
9
- Stable tag: 1.8.30
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -242,6 +242,10 @@ All script, style and body tags are stripped from html emails.
242
  Attachments are now processed in the order they were attached.
243
 
244
  == CHANGELOG ==
 
 
 
 
245
  = 1.8.30 (2017-02-06) =
246
  * Fixed bug where Postie won't run on PHP versions prior to 5.5.
247
 
@@ -1463,3 +1467,4 @@ plugin. And the rest is history :)
1463
  *
1464
  = 0.1 - 2004-06 =
1465
  * First release
 
6
  Tags: e-mail, email, post-by-email
7
  Requires at least: 3.3.0
8
  Tested up to: 4.7.2
9
+ Stable tag: 1.8.31
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
242
  Attachments are now processed in the order they were attached.
243
 
244
  == CHANGELOG ==
245
+ = 1.8.31 (2017-02-07) =
246
+ * Remove timezone warning if GMT+0
247
+ * Add postie_bare_link filter
248
+
249
  = 1.8.30 (2017-02-06) =
250
  * Fixed bug where Postie won't run on PHP versions prior to 5.5.
251
 
1467
  *
1468
  = 0.1 - 2004-06 =
1469
  * First release
1470
+