WP FullCalendar Image Thumbs on Full Calendar [closed]

To display the Event thumbnail in the associated cell on the Calendar, we can do without using the ‘WP FullCalendar’ as follows. First of all deactivate ‘WP Full Calendar’ (if already activated) To add the formatting we want, go to Events > Settings > Formatting > Calendar and add this code: #_EVENTIMAGE

A problem with date archives

The problem is that the plugin only handles the calendar part, and not the archive query. What you need to do: Change the main query on archive pages if the post_type argument is present, eg: http://localhost:8888/wp/?m=201105&post_type=candy : add_filter(‘pre_get_posts’, ‘atom_include_cpt_in_archives’); function atom_include_cpt_in_archives($query){ // validate if(is_archive() && isset($_GET[‘post_type’]) && post_type_exists($_GET[‘post_type’])) $query->set(‘post_type’, $_GET[‘post_type’]); return $query; } Next, you’ll … Read more

WP calendar summary attribute validation error

Update to 3.2.2. The summary attribute has been removed. See line 1149 \wp-includes\general-template.php WP v3.1.4: $calendar_output=”<table id=”wp-calendar” summary=”” . esc_attr__(‘Calendar’) . ‘”> WP v3.2.2: $calendar_output=”<table id=”wp-calendar”> Alternatives… To modify the output of the widget, you can duplicate it and rename it. When I did that, I also needed to duplicate the get_calendar() function and adjust … Read more

Modify query after meta value

Here’s an example using WP_Query‘s meta_query to query posts between two meta key values: $meta_query = array( array( ‘key’ => ‘event_date’, ‘value’ => array( $date_start, $date_end ), ‘compare’ => ‘BETWEEN’ ) ); $args = array( ‘posts_per_page’ => -1, ‘meta_key’ => ‘event_date’, ‘orderby’ => ‘meta_value’, ‘meta_query’ => $meta_query ); $results = new WP_Query( $args );

Post Terms As Class Name For Full Calendar Events

You are using get_single_term in a way that would require it to return a value… $term = get_single_term($post->ID, ‘course_locations’); … but you have written it in such a way that it echos a value. You should have… function get_single_term($post_id, $taxonomy) { $terms = wp_get_object_terms($post_id, $taxonomy); if(!is_wp_error($terms)) { return $terms[0]->name; } } I noticed a couple … Read more