This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

not displaying Featured image from custom post

Home Forums Product Support Forums Ajax Search Pro for WordPress Support not displaying Featured image from custom post

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #4232
    otcomotcom
    Participant

    Hello
    i’ve added the search bar to find only custom post. in origin this post had a custom field to get an image and to display on fronted i added this snippet on functions.php

    [php]function asp_cf_image( $image ) {
    if ($image != "" && strlen($image) < 10) {
    $atts = wp_get_attachment_image_src( $image );
    if (isset($atts[0]))
    return $atts[0];
    return null;
    }
    return $image;
    }[/php]

    now i’ve deleted that custom field to use the featured image panel and now i can’t get the image on search bar, it get only the default image.

    hope you can help me, thanks

    • This topic was modified 11 years, 2 months ago by otcomotcom.
    #4319
    otcomotcom
    Participant

    please, can you help me?

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.