WordPress.org

Ready to get started?Download WordPress

Forums

Hueman
[resolved] Setting featured image automatically (6 posts)

  1. mavieth
    Member
    Posted 3 months ago #

    Is there anyway to set the featured image as any image that appears in the post content/excerpt?

  2. mavieth
    Member
    Posted 3 months ago #

    For example, if I had an image link in my excerpt, it would automatically set that image to be the featured image. There will never be a case of having more than one image.

  3. stephencottontail
    Member
    Posted 3 months ago #

    I'm working on a solution right now. However, couldn't you just set the featured image when you originally write the post, or are you trying to do something more complicated than that?

  4. Alexander Agnarson
    Member
    Theme Author

    Posted 3 months ago #

  5. noaneo
    Member
    Posted 3 months ago #

    hello,

    The images must be processed by the "add media" function.

    have the first image of a post as featured image, we must put a code in functions.php

    https://premium.wpmudev.org/blog/daily-tip-how-to-automatically-set-the-featured-image-in-wordpress/

  6. mavieth
    Member
    Posted 3 months ago #

    Alex, thanks for such quick response times and helpful posts. It makes the theme that much better!

Reply

You must log in to post.

About this Theme

About this Topic