I have implemented Full Calendar via json with my Wordpress custom post types.
All is fine except I want to add the taxonomy term of the event / post to the 'className' of the event object but cant seem to get it working, can someone please take a gander at my implementation see where I am going wrong?
I cant seem to get my pasted code formatting legibly as such I have added a link to a pastebin, apologies, can be see here
get_single_term relates to a custom function to output the first term of the taxonomy as follows ....
function get_single_term($post_id, $taxonomy) {
$terms = wp_get_object_terms($post_id, $taxonomy);
if(!is_wp_error($terms))
{
echo $terms[0]->name;
} }
Thanks for any advice