Post By Email

0

Warning: This plugin is currently in beta! Use at your own risk and please report any bugs, either on the WordPress Support forums or via the Github issues page. Any new messages sent

Version
Last updated
Active installations
WordPress Version
Tested up to
Rating
Total ratings
Tags
This plugin is outdated and might not be supported anymore.

Description

Warning: This plugin is currently in beta! Use at your own risk and please report any bugs, either on the WordPress Support forums or via the Github issues page.

Any new messages sent to the configured email address will be posted to the blog. This plugin replaces the functionality that used to live in WordPress core.

Once an email has been successfully posted to the blog, it can either be marked as read (IMAP servers only) or deleted from the mailbox.

Updates on the project can be found on the Make WordPress Core blog.

Features

  • Supports IMAP or POP3 servers, with or without SSL
  • Optional PIN-based authentication guards against email spoofing
  • Uses WordPress’s built-in roles to manage which users can post
  • Set categories, tags and custom taxonomies by including shortcodes in your email
  • Email attachments will automatically be added to the post’s gallery
  • Emails from unauthorized users can be either set as pending or discarded

Post Authors and Security

The “From” address is matched to WordPress users in the database to determine the post’s author. If the author doesn’t have an account or isn’t allowed to publish posts, the post status will be set to “pending”.

By default, any users in the Author, Editor or Administrator roles are able to publish posts. Use the Users menu item in the admin dashboard to view and manage which users have this capability. For more information on the WordPress permissions system, see Codex: Roles and Capabilities.

Shortcodes

By default, emailed posts will be placed in the default category configured in the settings.

You can also set the categories, tags and custom taxonomy terms on your posts by including shortcodes in your email. These should be space-separated. Use slugs for tags (and non-hierarchical taxonomies) and either slugs or IDs for categories (/ hierarchical taxonomies). Terms that do not yet exist will be created. Examples:

Categories: Use either slugs or IDs.
[category posted-by-email another-category]
[category 14]

Tags: Use slugs.
[tag cool-stuff]

Custom Taxonomies: Use slugs for non-hierarchical taxonomies, and IDs for hierarchical.
[custom-taxonomy-name thing1 thing2]
[another-custom-taxonomy 2 3 5]

Attachments

Any files attached to an email will be uploaded to the Media Library and added to the post as a gallery. You can specify gallery options, or its location within the post, by including a gallery shortcode in your email. If no gallery shortcode exists, it will be added to the end of the post.

Testing

Automated Tests

Like WordPress Core, this plugin includes automated unit tests written in PHPUnit.

To run the unit tests:

  1. Set up the WordPress testing library as described in Handbook: Automated Testing. You can also do this using WP-CLI.
  2. From the plugin directory, run WP_TESTS_DIR=/path/to/WordPress/test/install phpunit

Manual Testing

  1. Set up a test email address (services such as Gmail work great for this) and enable IMAP or POP3 access. (Refer to Installation for detailed instructions.)
  2. Verify that you are using the correct mailbox settings by using a third-party email client, such as Outlook or OSX Mail.app, to connect to your test mailbox.
  3. Enter those settings into the Post By Email settings and save them.
  4. Navigate to the “Activity Log” tab and press the “Check Now” button. When the page reloads, you should see a new entry in the log file describing the results of the mail check.

Caveat: There is sometimes a delay between sending an email and having it show up in the mailbox, especially with POP3. If you’re using IMAP, you can connect using a third-party mail client to verify that messages have been received, then mark them as unread so Post By Email will pick them up.

Reporting Bugs

Before reporting a bug, make sure you’ve updated the plugin to the latest version.

Then, provide as much of the following information as possible:

  1. WordPress version (e.g. 3.6.x).
  2. Plugin version (e.g. 1.0.4).
  3. PHP version (e.g. 5.2.x or 5.3.x).
  4. Your mailbox settings (URL, protocol, port and whether SSL is enabled; not your login and password).
  5. Any error messages displayed (it might help to enable WP_DEBUG in your wp-config.php).
  6. If the issue is related to a specific email, the full email, including headers. Feel free to replace any personal information with dummy text (such as “sender@example.com”). This link has instructions for viewing full message headers in Gmail, Outlook and Yahoo.