Title: Events Category Calendar link problem
Last modified: February 10, 2024

---

# Events Category Calendar link problem

 *  Resolved [UKuG Webmaster](https://wordpress.org/support/users/murray2024/)
 * (@murray2024)
 * [2 years, 3 months ago](https://wordpress.org/support/topic/categot/)
 * In Event category pages I have a simple bit of code for adding a list of events
   to your calendar such as this:
 * **Upcoming Events**
 *     ```wp-block-code
       #_CATEGORYNEXTEVENTS
       Add all events to calendar: #_CATEGORYICALLINK
       ```
   
 * The problem (which i believe is a bug) is that the category Ical link is not 
   adding future events. The ics files give a list of ancient historic ones and 
   stop short of current
 * Tested on two websites
 * [https://www.microwavers.org/main/events/categories/contest/](https://www.microwavers.org/main/events/categories/contest/)
 * [http://www.g0mwt.org.uk/main/events/categories/meetings/](http://www.g0mwt.org.uk/main/events/categories/meetings/)
    -  This topic was modified 2 years, 3 months ago by [UKuG Webmaster](https://wordpress.org/support/users/murray2024/).
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fcategot%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  [joneiseman](https://wordpress.org/support/users/joneiseman/)
 * (@joneiseman)
 * [2 years, 3 months ago](https://wordpress.org/support/topic/categot/#post-17418885)
 * The problem is that $args is set for the category page but then the $args is 
   used in the ical.php template file. You can fix this problem as follows:
 * Create the directory wp-content/plugin-templates/events-manager/templates and
   then copy the file wp-content/plugins/events-manager/templates/templates/ical.
   php to that directory and then in the copied version of ical.php change the following
   lines starting at line 13 from this:
 *     ```wp-block-code
       //get passed on $args and merge with defaults
       $args = !empty($args) ? $args:array(); /* @var $args array */
       $args = array_merge(array('limit'=>$page_limit, 'page'=>'1', 'owner'=>false, 'orderby'=>'event_start_date,event_start_time', 'scope' => get_option('dbem_ical_scope') ), $args);
       ```
   
 * To this:
 *     ```wp-block-code
       $args = array('limit'=>$page_limit, 'page'=>'1', 'owner'=>false, 'orderby'=>'event_start_date,event_start_time', 'scope' => get_option('dbem_ical_scope') );
       ```
   
 * I think a similar change should also be made in rss.php.

Viewing 1 replies (of 1 total)

The topic ‘Events Category Calendar link problem’ is closed to new replies.

 * ![](https://ps.w.org/events-manager/assets/icon-256x256.png?rev=1039078)
 * [Events Manager - Calendar, Bookings, Tickets, and more!](https://wordpress.org/plugins/events-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager/reviews/)

## Tags

 * [categories](https://wordpress.org/support/topic-tag/categories/)
 * [ical](https://wordpress.org/support/topic-tag/ical/)

 * 1 reply
 * 2 participants
 * Last reply from: [joneiseman](https://wordpress.org/support/users/joneiseman/)
 * Last activity: [2 years, 3 months ago](https://wordpress.org/support/topic/categot/#post-17418885)
 * Status: resolved