I want to test if my category seminar has any events assigned. If it does I’m going to do one thing, if it doesn’t I’m gonna do something else. Any help with this greatly appreciated.
cudafunk,
Thanks for getting in touch! Our plugin uses standard WordPress custom post types for our Events, so you should be able to use WP_QUERY in order to see if any events exist in a category. Something like this should do the trick: https://gist.github.com/ckpicker/263c31e83d4a0f9a3f17
Give that a try and let me know if that gets you started in the right direction. Thanks! 🙂
I just wanted to follow up and see if you’re all set here or if you still have further questions. Just let me know if you have further questions or if I should go ahead and close out this thread. Thanks! 🙂
Since I haven’t heard back from you here, I’m going to go ahead and close out this thread. Feel free to start a new thread if you have further issues. Thanks! 🙂
-Casey-
Author
Posts
Viewing 4 posts - 1 through 4 (of 4 total)
The topic ‘Check if Category has events assigned’ is closed to new replies.