2

I'm new to editing blogger themes and hope someone that recognizes <b: if> code can help out.

This is what I want to learn and put into my blogspot theme:

If a post has a specific thumbnail, or not found, display another image.

Something like this logic?

If thumb=='bad_picture_name' .or. thumb=='another_bad_pic_name'

    Display good_picture

Elseif thumb==missing

    Display transparent_gif-thumb

Else

    Display thumb

Endif
2

Your code should be like this : (works with new themes)

<b:if cond='data:post.featuredImage'>
    <b:if cond='data:post.featuredImage == "img-src" or data:post.featuredImage == "img-src"'>
         Display good_picture
    <b:else/>
        Display thumb
    </b:if>
<b:else/>
    Display transparent_gif-thumb
</b:if>

With old templates (version 2) replace featuredImage with firstImageUrl

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.