sanderpinkse 0 Report post Posted June 5, 2011 I just discovered featured images are not working for custom post types in PlatformPro. That is because support for featured images needs to be declared explicitly for every post type in functions.php. Adding support for my custom post type in functions.php in PlatformBase didn't work. The only solution I could find was editing core.init.php directly. That does work, but surely there has to be a better way to handle this? Cheers, Sander Share this post Link to post Share on other sites
evert100 1 Report post Posted June 5, 2011 Hey Sander, Kan je niet emailen daarom even zo. Wat is je website, ben benieuwd! De mijne vind je hier: www.edugram.nl <just a small dutch talk> Cheers Share this post Link to post Share on other sites
sanderpinkse 0 Report post Posted June 5, 2011 To clarify my previous message: when I'm talking about featured images, I mean post thumbnails, not the images in a feature slider. Share this post Link to post Share on other sites
Simon 248 Report post Posted June 5, 2011 Sander can you post your 'add support' code please. Share this post Link to post Share on other sites
sanderpinkse 0 Report post Posted June 6, 2011 Hi Simon, I'd like to, but I'm afraid I haven't got a clue what an "add support code" is. Sorry... Share this post Link to post Share on other sites
Simon 248 Report post Posted June 6, 2011 I mean what code are you using to declare your custom post type? Share this post Link to post Share on other sites
sanderpinkse 0 Report post Posted June 6, 2011 Ah! Sorry for being a bit dense. I don't declare them myself, but have been using the "Custom Post Type UI" plugin. If I change add_theme_support( 'post-thumbnails', array('post') ); in core.init.php to add_theme_support( 'post-thumbnails', array('post', 'my_custom_post_name') ); the featured image field shows up in the backend on my CPT pages. Cheers, Sander Share this post Link to post Share on other sites
cmunns 16 Report post Posted June 6, 2011 So then this is resolved? Share this post Link to post Share on other sites
sanderpinkse 0 Report post Posted June 6, 2011 Well, in the sense that I can get the post thumbnails to behave properly, yes. But the only solution I could find was editing core.init.php. Not an ideal solution, to put it mildly. I could do a lot of damage there. And my edits will be wiped out the next time you guys do an update... Cheers, Sander Share this post Link to post Share on other sites
cmunns 16 Report post Posted June 7, 2011 You can add the add_theme_support function directly to the functions.php file in -Base Share this post Link to post Share on other sites
sanderpinkse 0 Report post Posted June 13, 2011 Thanks! That was the first thing I tried, but it didn't work for me at the time. I probably made a typo, because now it works like a charm. Thanks for the help! Share this post Link to post Share on other sites