Featured Content Gallery | WordPress Plugin | iePlexus

Support for Wordpress Featured Image

New releases, ideas for the future, and known issues

Support for Wordpress Featured Image

PostBy guyn on Sun Feb 20, 2011 6:59 am

Hi guys,

I'm guessing someone already did this before, but here is a quick solution for allowing the Featured Content Gallery to automatically pull the featured Image from each post.

This is actually quite simple and only require minor changes to the code.

gallery.php
go to line 45-48 (two regular image calls) remove them / mark them out and add the following two lines of code :

Code: Select all
<?php the_post_thumbnail ('Main Photo') ?>
<?php the_post_thumbnail ('mini Photo') ?>                


Notice that Main Photo/mini Photo are the names of the featured image sizes defined in your template (you can define new sizes using add_image_size command in functions.php)

scripts/jd.gallery.js.php
We need to change line 61-62.
Code: Select all
imageSelector: "img.[class name]",
thumbnailSelector: "img.[class name]",

where [class name] is the name of the class used for the featured image size (usually attachment-sizename)

Hope this helps anyone.
Guy
guyn
 
Posts: 1
Joined: Sun Feb 20, 2011 6:46 am

Re: Support for Wordpress Featured Image

Thank you for using the Featured Content Gallery Forum
 

Return to Development, Improvement, and Conflicts

Who is online

Users browsing this forum: No registered users and 0 guests

cron