Home Forums Plugin Support WP User Frontend Pro Show Images in post

This topic is: not resolved

Tagged: ,

This topic contains 4 replies, has 3 voices, and was last updated by  Tareq Hasan 5 years, 3 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #17037

    Post count: 30

    Hello, I am trying to show the images in post content.

    I have already unchecked the “Show custom fields on post content area” in the General settings.

    Here following is what I want (seen from the back-end dashboard).
    Thank you in advance for your help.


    Post count: 1555

    If you unchecked meta fields to show then try with this tutorial here: http://docs.wedevs.com/showing-meta-fields-in-frontend/#showing-fields-in-the-theme


    Post count: 30

    I am not sure I understand.

    1-this is into my single-posttype.php

    <?php echo get_post_meta( $post->ID, ‘images', true ); ?>

    2-this is into my function.php

    $images = get_post_meta( $post->ID, ‘mey_key_name' );

    if ( $images ) {
    foreach ( $images as $attachment_id ) {
    $thumb = wp_get_attachment_image( $attachment_id, ‘thumbnail' );
    $full_size = wp_get_attachment_url( $attachment_id );

    printf( ‘%s‘, $full_size, $thumb );

    What I got is a number that appears at the bottom of the post


    Post count: 30

    Or there is a way to reset options to default?


    Tareq Hasan
    Post count: 2831

    You are doing it wrong. Paste the #2 in your single-posttype.php. You don't need that in functions.php and also #1 is not needed.

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘Show Images in post’ is closed to new replies.