WordPress.org

Ready to get started?Download WordPress

Forums

WP-EMail
[resolved] Embed Post_Image in Mail? (9 posts)

  1. planetshaker
    Member
    Posted 1 month ago #

    I can embed the Post_Title - but how to embed the post_image? Should be another variable, shouldn't it?

    https://wordpress.org/plugins/wp-email/

  2. Lester Chan
    Member
    Plugin Author

    Posted 1 month ago #

    If the post image is within the post content, it will send it. However, you can't embed post image.

  3. planetshaker
    Member
    Posted 1 month ago #

    Okay, is that a wordpress restriction? Could a post image variable technically exist? Would make the email more beautiful.

  4. Lester Chan
    Member
    Plugin Author

    Posted 1 month ago #

    Nope, it is not. The post image doesn't exist in the plugin itself or rather when emailing out the post, it doesn't fetch the image.

  5. planetshaker
    Member
    Posted 1 month ago #

    Okay, last try to pose my question "straightly" ;-)
    Can the plugin be adapted in this way that there will be a new variable that gets the post image out? Or is there a wordpress restriction that doesn't allow this? Otherwise, I suppose, you would have done this, wouldn't you?

  6. Lester Chan
    Member
    Plugin Author

    Posted 1 month ago #

    Nope there is no restriction on WP side. I did not add it because I don't see a need for it.

  7. planetshaker
    Member
    Posted 1 month ago #

    Thanks, that's what I wanted to know.

    Maybe I'll alter the plugin then. I definitely see a need for it: Posts can be recommended in a much nicer way when people also see the post image instead of just having the title with the excerpt or the content (with content images, of course). I even can make a nice HTML template with (of course,) inline CSS, since the Plugin strips out all CSS or header information from the html. Maybe this will increase the click rate on a recommendation mail significantly.

    Thanks for your info.

  8. Lester Chan
    Member
    Plugin Author

    Posted 1 month ago #

    Sounds good! Feel free to fork it https://github.com/lesterchan/wp-email and submit pull request if needed =)

  9. planetshaker
    Member
    Posted 1 month ago #

    I have adapted the plugin. You now can use two new variables:

    - %EMAIL_POST_IMAGE%
    - %EMAIL_POST_URL%

    The first inserts the <img>, the second only the URL of the image.

    Additionally, there is a new Dropdown Field for selecting the size of the used post image:

    Screenshot

    Feel free to check and correct/adapt it if needed, would be good to take this as further basis for updates of the plugin.

    Download the plugin with Image variable

    You can test it on every article in the beautytipps-blog.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.