Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPB Kupası
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

WordPress’te Birden Fazla Yazı Küçük Resmi / Öne Çıkan Görsel Nasıl Eklenir

Editoryal Not: WPBeginner üzerindeki ortak bağlantılardan komisyon kazanıyoruz. Komisyonlar, editörlerimizin görüşlerini veya değerlendirmelerini etkilemez. Editoryal Süreç hakkında daha fazla bilgi edinin.

Bir WordPress gönderisine birden fazla gönderi küçük resmi veya öne çıkan resim eklemenin bir yolunu mu arıyorsunuz?

Varsayılan olarak, çoğu WordPress teması, yazı küçük resimleri eklemeyi gerçekten basit hale getiren öne çıkan görüntüler için yerleşik destekle birlikte gelir. Ancak, özel projeler üzerinde çalışırken, bir blog gönderisine veya sayfasına ikinci bir öne çıkan görsel eklemeniz gerekebilir.

Bu makalede, WordPress’te birden fazla yazı küçük resmini / öne çıkan görüntüyü nasıl ekleyeceğinizi göstereceğiz.

How to add multiple post featured images in WordPress

WordPress’te Neden Birden Fazla Öne Çıkan Görsel Eklemelisiniz?

Öne çıkan görseller varsayılan bir WordPress özelliğidir ve bunları her WordPress temasında bulabilirsiniz. İçeriğinize hayat vermeye ve blog yazılarınızı daha ilgi çekici hale getirmeye yardımcı olurlar. Ayrıca, kullanıcının dikkatini çekmeye ve makalenize tıklamasını sağlamaya yardımcı olurlar.

WordPress web sitenize birden fazla gönderi küçük resmi eklemeniz gerekebilecek durumlar vardır. Belki bir müşterinin birden fazla küçük resim kullanmak için özel bir gereksinimi vardır veya web sitenizin tasarımı çeşitli görüntüler gerektirir.

Örneğin, farklı resim boyutları gerektiren ana sayfa veya arşiv sayfaları (blog ve kategori bölümü) gibi bölümleriniz olduğunu varsayalım. Bu durumda, birden fazla küçük resim görüntüleme seçeneğine sahip olmak gerçekten yararlıdır.

WPBeginner’da arşiv sayfaları, sosyal medya ve bir blog gönderisinde görünen küçük resimler için birden fazla öne çıkan resim kullanıyoruz. İşte blog gönderisi içinde görünen bir küçük resim:

Thumbnail that appears in post

Öte yandan, arşiv sayfalarında görünen resimler farklıdır.

İşte WPBeginner’daki blog bölümünde küçük resimlerin nasıl göründüğüne bir bakış:

Thumbnails on archive pages

Şimdi, WordPress’te nasıl birden fazla küçük resim ekleyebileceğinizi görelim.

WordPress’te Eklenti Olmadan Birden Fazla Öne Çıkan Görsel Ekleme

Eklentiler olmadan birden fazla öne çıkan görsel eklemenin en basit yolu, bunları WordPress içerik düzenleyicisinde içeriğinize manuel olarak yerleştirmektir.

İlk olarak, WordPress içerik düzenleyicisindeki varsayılan öne çıkan görsel seçeneğine birincil küçük resminizi yükleyebilirsiniz.

Sağ taraftaki ayarlar panelini açmak için üstteki dişli çark simgesine tıklamanız ve ardından ‘Öne çıkan görsel’ bölümüne gitmeniz yeterlidir.

Upload primary featured image in content editor

Bundan sonra, ‘Öne çıkan görseli ayarla’ alanına tıklayın ve WordPress medya yükleyicisi açılacaktır.

Devam edin ve resminizi yükleyin veya mevcut medya kitaplığınızdan bir resim seçin.

Upload your image

Bir görsel seçtikten sonra, ‘Öne çıkan görseli ayarla’ düğmesine tıklamanız yeterlidir.

Ardından, başka bir öne çıkan görsel eklemek için içeriğin herhangi bir yerine bir görsel bloğu ekleyebilirsiniz.

Devam edin ve ‘+’ düğmesine tıklayın ve ardından ikincil öne çıkan görseli görüntülemek istediğiniz yere bir görsel bloğu ekleyin.

The WordPress Image block

Resim bloğu eklendikten sonra, küçük resmi blog gönderinize yüklemeniz yeterlidir.

Ayrıca‘Medya Kitaplığı‘ndan bir görüntü seçebilir veya ‘URL’den ekle’ seçeneğini kullanabilirsiniz.

Upload or select an image from media library

Bunun yanı sıra, bir galeri bloğu ekleyebilir ve birden fazla öne çıkan görsel gösterebilirsiniz. Bu özellikle bir e-ticaret mağazanız varsa veya çok sayıda yüksek kaliteli ürün görseli göstermeniz gerekiyorsa kullanışlıdır.

Daha fazla ayrıntı için lütfen WordPress’te resim galerisi oluşturma kılavuzumuza bakın.

Artık WordPress web sitenizi ziyaret ederek birden fazla öne çıkan görsel görebilirsiniz.

Preview of multiple featured images

WordPress’te Kategori Öne Çıkarılmış Görsel Nasıl Elde Edilir

Belirli bir kategorideki makaleler için farklı bir öne çıkan görsel göstermek istiyorsanız, en iyi çözüm Kategori Öne Çıkan Görsel eklentisini kullanmaktır.

Öncelikle Kategori Öne Çıkan Görsel eklentisini yüklemeniz ve etkinleştirmeniz gerekir. Yardıma ihtiyacınız varsa, lütfen bir WordPress eklentisinin nasıl kurulacağına ilişkin kılavuzumuza bakın.

Eklenti etkin olduğunda, WordPress panonuzdan Yazı ” Kategoriler bölümüne gidebilirsiniz. Artık yeni kategoriler veya alt kategoriler eklerken yeni bir ‘Öne çıkan görsel’ seçeneği göreceksiniz.

Başlamak için ‘Yeni görsel ekle’ düğmesine tıklamanız yeterlidir.

Add category featured images

Düğmeye tıkladığınızda, WordPress medya yükleyicisi açılacaktır.

Görselinizi yükleyebilir veya WordPress medya kitaplığınızdan bir tane seçebilir ve ‘Öne çıkan görseli ayarla’ düğmesine tıklayabilirsiniz.

Upload your image

Bunun yanı sıra, web sitenizdeki mevcut kategorileri düzenleyebilir ve öne çıkan bir resim ekleyebilirsiniz.

İlk olarak, mevcut herhangi bir kategorinin üzerine gelin ve ardından ‘Düzenle’ seçeneğine tıklayın.

Edit an existing category

Bundan sonra, ‘Öne çıkan görsel’ bölümüne kaydırın.

Devam edin ve ‘Yeni görsel ekle’ düğmesine tıklayın ve kategori için öne çıkan görselinizi yükleyin.

Add a featured image to existing category

İşiniz bittiğinde ‘Güncelle’ düğmesine tıklamayı unutmayın.

Artık WordPress yönetici panelinizdeki Kategoriler sayfasına geri dönebilir ve her kategori için öne çıkan görseli görebilirsiniz.

View featured image for each category

Bu makalenin WordPress’te birden fazla gönderi küçük resmi / öne çıkan resim eklemeyi öğrenmenize yardımcı olduğunu umuyoruz. Ayrıca bir blog platformunun nasıl seçileceği ve en iyi ücretsiz işletme adı oluşturucu hakkındaki kılavuzumuza da bakabilirsiniz.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Açıklama: İçeriğimiz okuyucu desteklidir. Bu, bazı bağlantılarımıza tıklarsanız komisyon kazanabileceğimiz anlamına gelir. WPBeginner'ın nasıl finanse edildiğini, neden önemli olduğunu ve nasıl destek olabileceğinizi görün. İşte editoryal sürecimiz.

Avatar

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

Ultimate WordPress Araç Kiti

Araç setimize ÜCRETSİZ erişim sağlayın - her profesyonelin sahip olması gereken WordPress ile ilgili ürün ve kaynaklardan oluşan bir koleksiyon!

Reader Interactions

60 yorumBir Cevap Bırakın

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. THANKGOD JONATHAN says

    Having multiple post thumbnails seemed like a complex task until I found this tutorial. Your explanation and recommended plugins made it straightforward. Thanks for simplifying the process!

  3. Thodoros Athineos says

    This is very handy for many purposes that special images might be needed (eg mobile-image).

    BUT
    Is it possible for your future plans, to provide the ability of an array of images, instead of single?

    For example, the developer might need to add an album-images instance, in order that user can select multiple images to be provided to an album.

    • WPBeginner Support says

      We will look into possibly adding that in the future but you may need to look into a plugin for that level of customization.

      Yönetici

  4. Robin Parker says

    hi, everything works down to this paragraph.

    “Even though you can add a secondary featured image in your WordPress admin, it will not display on your site until you configure your theme. All you need to do is add the following code inside your post loop where you want to display it. This could be in your single.php (for single posts), archive.php (only for archive pages), etc.”

    Can you explain a little more about where to place this part of the code within the theme? Thx!

    • WPBeginner Support says

      That would depend on your specific theme, normally it should have the code to display your content and you would place the code in that area, for understanding the loop you would want to take a look at the page: https://www.wpbeginner.com/glossary/loop/
      For where to place the code for how you’re wanting it, you would want to reach out to your theme’s support.

      Yönetici

  5. Parvez says

    I want to add two images; one as a thumbnail (in search engine, archives, homepage or any other place it showed) and another one as featured image (Reader will see this image only at the time of reading content).

    Is there any solution for my problem?

    • WPBeginner Support says

      You would want to reach out to the support for the theme you are using for that type of customization.

      Yönetici

  6. Lisa says

    Hi. Could you possibly update older articles? This one uses a plugin that hasn’t been updated in over 2 years.

    Just wondering.

    • Kashif Riaz says

      Hi, Please tell me how to access the second thumbnail. For example we can access the default featured image by “the_post_thumbnail()”.

  7. Kristina says

    Why isn’t the “Multiple Post Thumbnails” updated? It said that it was last updated 2 years ago. It needs to be updated because some people cannot use plugins that wasn’t updated since 2-3 years ago…

  8. Leslie says

    I hope you can help me. Can you tell me if this plugin can do what I need?

    I need to be able to add a second featured image to a post (or custom post type) that is in more than one category. On the archive page for one of the categories, I need for the second featured image thumbnail to show, and everywhere else on the site I need for the first featured image thumbnail to show.

    Thanks for whatever you can tell me!

  9. Nick W says

    I use genesis and i cannot figure out where to paste this snippet so the 2nd featured image shows only as the thumbnail on the home and category pages. Please help.

  10. Lance says

    Great Plugin! Could it be possible to make it so when there is a secondary image set, that only the secondary image shows?

  11. Brian says

    Can you add it to just one page in the admin area. Like if i wanted to just add it to the front-page.php file in the admin area so if you go to edit another page it is not on it in the admin area?

  12. Neil desucatan says

    Hi i’m new with wordpress and i hope you can help me :) with this

    i need to use this to my sidebar.php but now showing the secondary image

  13. Anas Iqbal says

    Hi, I am using this plugin with NewsPaper WordPress theme but everytime it display the latest secondary image added in all post.

    Like I display 6 posts in sidebar, and secondary image was added in just first 2 posts, but the same image will display in all 6 posts.

    Please tell me how can I use this with NewsPaper WordPress theme.

  14. Barrett Hemmings says

    Is there a way to use this method to assign a secondary featured image based on a category that is chosen? I am building a site for a reclaimed wood company that does all kinds of projects and some of the project photos have multiple categories within them. For instance, one project we did has items throughout the house that we did, and we included the category “Shelves” to a posting that the featured image doesn’t show any shelves. That project will be displayed within a page of shelves and have the featured image of a counter top. Is there any way to make it display one of the photos of the shelves when it is displayed in this category?

    • Ankita says

      there is always an id for any post type so in your case if it is “shelves” then ‘post_type’ => ‘shelves’ will be in your code.

  15. tareq says

    It’s really working on post. bt i wanna set it on custom post. How can i add multiple feature image in custom post?

  16. Patrick Buntsma says

    It might be very easy, but I cannot seem to get it right…
    How do I get it to show up in all my post types? The ‘post_type’ => ‘post’ only makes it available in WP Posts. I need it in ‘page’ and ‘event’ as well.

    Please advice.

  17. Anas Naqvi says

    for multiple feature images copy this code in your functions,php

    if (class_exists(‘MultiPostThumbnails’)) {

    for($i=2; $i ‘Secondary Image-‘.$i,

    ‘id’ => ‘secondary-image-‘.$i,

    ‘post_type’ => ‘page’

    ));

    }

    }

    In order to display your featured image paste this code in your loop of your single.php/page.php where you want to display the images.

    if (class_exists(‘MultiPostThumbnails’)) :

    for($i=2; $i<=5; $i++)

    {

    MultiPostThumbnails::the_post_thumbnail(get_post_type(), 'secondary-image-'.$i);

    }

    endif;

  18. Rajith Gunawardena says

    this is a very useful tutorial.. So the admins doesn`t need to go to widgets as all items could be added at once ( if the items are unique to that post ./ page ) .. Does anyone of you guys know how we could have a similar one for featured text and extra text areas within the post ?

    • KyawNaing Tun says

      I solved it like this :)

      // in function.php

      if (class_exists(‘MultiPostThumbnails’)) {

      new MultiPostThumbnails(array(

      ‘label’ => ‘Secondary Image’,

      ‘id’ => ‘secondary-image’,

      ‘post_type’ => ‘product’

      ) );

      new MultiPostThumbnails(array(

      ‘label’ => ‘Third Image’,

      ‘id’ => ‘third-image’,

      ‘post_type’ => ‘product’

      ) );

      }

      // in template

      if (class_exists(‘MultiPostThumbnails’)) :

      MultiPostThumbnails::the_post_thumbnail(get_post_type(), ‘secondary-image’);

      endif;

      if (class_exists(‘MultiPostThumbnails’)) :

      MultiPostThumbnails::the_post_thumbnail(get_post_type(), ‘third-image’);

      endif;

  19. MatsDagerlind says

    I solved it like this (based on code provided in this article, its comments and other sources):

    MultiPostThumbnails::the_post_thumbnail(get_post_type(), ‘secondary-image’, NULL, ‘medium’);
    $mptId = MultiPostThumbnails::get_post_thumbnail_id(‘post’, ‘secondary-image’, $post->ID);
    $p = get_post($mptId);
    echo “”;
    echo apply_filters(‘the_excerpt’,$p->post_excerpt);
    echo “”;

  20. Vinnie James says

    Is it possible to just return the image url without the tag when calling it up within the template file? Something similar to:

    //Get the Thumbnail URL
    $src = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), array(320,240), false, ” );
    echo $src[0];

    EDIT: Yes, there is. Use this —
    $custom = MultiPostThumbnails::get_post_thumbnail_id(‘post’, ‘secondary-image’, $post->ID); $custom=wp_get_attachment_image_src($custom,’post-secondary-image-thumbnail’); echo $custom[0];

  21. Mehdi says

    Hi, Thank you for your work :)

    Using this plugin, can I add more than 1 additional Thumbnail image ??

    Thank you.

      • Mehdi says

        Awesome! But it looks that from the back-office I can only add One secondary image. How can I achieve that ?
        Thank you.

        • Mehdi says

          Sorry, this is how we can do it :

          // To be Added in functions.php
          // Multi-Thumbnails code
          if (class_exists(‘MultiPostThumbnails’)) {
          for($i = 1; $i ‘Gallery Image’.$i,
          ‘id’ => ‘image-‘.$i,
          ‘post_type’ => ‘post’
          ));
          }
          }

          Thank you.

    • WPBeginner Support says

      The featured image is an image that you can attach to a post using the featured image box in the post edit area. If you want, you can set a default fallback image for your featured images. This default featured image will appear when there is no featured image set for a post.

      Yönetici

  22. Gunaseelan says

    I have created a plugin for displaying Page Title, Featured Image and the content.

    Instead of displaying featured image, I need to display the secondary image that is uploaded via plugin.

    How to accomplish this? I will share a small part of my plugin. Please go through it.

    function widget($args, $instance) {
    extract( $args );
    $title = apply_filters(‘widget_title’, $instance[‘title’]);
    $page_id = $instance[‘page_id’];
    $featured_image = get_the_post_thumbnail($page_id);
    $image = $instance[$featured_image];
    echo $featured_image;

    ?>

    post_content;
    $content = strip_shortcodes($content);
    $content = apply_filters(‘the_content’, $content);
    echo $this->break_text($content, $page_id);
    ?>

    <!––>
    <!––>

    <?php
    }

  23. Eoghan says

    I cannot get the resize part to work for me.

    I add image size in functions.php:
    add_image_size(‘small-featured-image-size’, 250, 150);

    I add my image:
    if (class_exists(‘MultiPostThumbnails’)) {
    new MultiPostThumbnails(
    array(
    ‘label’ => ‘Small Featured Image’,
    ‘id’ => ‘smaller-featured-image’,
    ‘post_type’ => ‘product’
    )
    );
    }

    And then:
    if( class_exists(‘MultiPostThumbnails’) ) {
    MultiPostThumbnails::the_post_thumbnail(‘product’, ‘smaller-featured-image’, NULL, ‘small-featured-image-size’);
    }

    The image keeps coming out on the page as its original size. Can anyone help me?

  24. Joshua says

    Hey, I’m trying to figure out how to turn this block of code into an array that can be used outside of the loop (in a foreach loop thats after the post loop).

    if (class_exists(‘MultiPostThumbnails’)) :

    MultiPostThumbnails::the_post_thumbnail(get_post_type(), ‘secondary-image’);

    endif;

    How would you do this? Great tutorials by the way!

  25. Aura Ide says

    Thank you for this article as I was looking for a long time, it turns out I found here. We will practice immediately. The tutorial is very clear, good luck!

  26. Travis Pflanz says

    To improve on this idea, you could just use a custom meta box/fields plugin or create a custom repeatable field… To allow different number of “post thumbnails”

Bir Cevap Bırakın

Yorum bırakmayı seçtiğiniz için teşekkür ederiz. Lütfen tüm yorumların yorum poli̇ti̇kasi uyarınca denetlendiğini ve e-posta adresinizin yayımlanmayacağını unutmayın. Ad alanında anahtar kelime KULLANMAYIN. Kişisel ve anlamlı bir sohbet edelim.