Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialMarcus Tisäter
4,886 PointsWordPress Shortcode sort by category
Hi,
I am creating my own slideshow plugin. The user can add a category for each slide and I want by shortcode to display it, sort of like
[shortcode category="my_awesome_slideshow_category]
and that would display all my slides that are in my_awesome_slideshow_category
Any tip?
Thanks
1 Answer
Zac Gordon
Treehouse Guest TeacherWhat Dennis suggests is pretty spot on although this should really be included as a plugin and not in the theme itself. Were you able to work out how to do this?
Dennis Eitner
Full Stack JavaScript Techdegree Graduate 25,644 PointsDennis Eitner
Full Stack JavaScript Techdegree Graduate 25,644 Pointshope this helps:
create a custom post type add custom fields create a shortcode function in your functions.php file