Make custompress not show default.png

I have used CustomPress to make a Project Step by Step tutorial post page. I have absolutely zero PHP knowledge so making it this far for me is a shock. My last hurdle is to allow, but not require images to be uploaded.

That said, if an image is not uploaded, currently CustomPress is pulling default.png from my media folder. I would like the upload media option to not call anything whatsoever if an image is not uploaded. How would I achieve such a thing?

I have attached a screenshot of what is happening currently, with the default.png showing for all image upload areas. That said, if the image upload isn't pulling the default, then the numbered sections will not appear (which is the desired outcome).

  • Sajid

    Hi @Gary,

    Hope you are doing good today :slight_smile:

    Its not CustomPress that is pulling the default.png image if no featured images is assigned. In fact its WordPress function and its solely upto theme author to allow this feature or not.

    First of all switch to defaul theme and then check again. If the default images gone then switch back to original theme.

    Go to wp-content/themes folder via FTP or FileManager. Find following code in your theme (should be content.php but it still depends upon theme author) and remove the third parameter.

    wp_get_attachment_image_src

    So it will be like this before:
    wp_get_attachment_image_src($thumb_id,'full', true);

    ...and after:
    wp_get_attachment_image_src($thumb_id,'full');

    Hope that helps! Feel free to post a reply if you need further assistance :slight_smile:
    Cheers, Sajid

  • Gary

    Sajid,
    Unfortunately that does not appear to have worked :-\

    I have located that exact line of code in my theme-functions.php file, and made the change that you've recommended, and it has not changed the issue at hand.

    My theme is Canvas by WooThemes, I don't know if that information is helpful. As I'd mentioned before I am completely lost in the world of PHP, and in an effort to see if I was missing something I removed the true designation any time I found wp_get_attachment_image_src

    Unfortunately that did not work either. Any other ideas?

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.