Home › Forums › Calendar Products › Events Calendar PRO › Use the_widget for Event Tribe Widgets with arguments
- This topic has 6 replies, 2 voices, and was last updated 13 years, 1 month ago by
Barry.
-
AuthorPosts
-
March 16, 2013 at 1:56 pm #42934
Denise Crosbie
ParticipantI am reading post: https://theeventscalendar.com/support/forums/topic/upcoming-events-in-page-template/#post-30779
I see I can call the_widget function for the following Tribe widgets:
TribeEventsListWidget()
TribeEventsAdvancedListWidget()
TribeEventsCalendarWidget()
TribeEventsFeatureWidget()But this topic doesn’t help me discover the arguments that I can use. For example when I use the Advanced List widget I can select an event category. but, I don’t know what argument to pass in to the_widget function to pass in the event category?
March 16, 2013 at 2:01 pm #42937Denise Crosbie
ParticipantDigging through the code I see that I can use “category”, I use it like this:
the_widget(‘TribeEventsAdvancedListWidget’,’category=11′);
Which works.Is there a doc that specifies these settings for future reference?
March 16, 2013 at 2:03 pm #42938Barry
MemberKeys you might pass in as part of the instance array could include:
- title
- limit
- no_upcoming_events
- start
- end
- venue
- country
- address
- city
- region
- zip
- phone
- cost
- category
You don’t need to pass in all of them of course, just those where you need to change the value to something non-default.
March 16, 2013 at 2:16 pm #42943Denise Crosbie
ParticipantAre those valid just for TribeEventsAdvancedListWidget or for TribeEventsCalendarWidget as well? I am also looking to filter TribeEventsCalendarWidget by category.
March 16, 2013 at 2:21 pm #42945Barry
MemberTribeEventsCalendarWidget is slightly different and I believe the only argument passed in is title … so to restrict it to a specific category you might instead override table-mini.php and make some changes to the tribe_get_events() call in that template.
Some good resources:
Hope that helps 🙂
March 18, 2013 at 4:16 pm #43199Denise Crosbie
ParticipantThanks for the list on TribeEventsAdvancedListWidget I am using the category filter and it works great. For the TribeEventsCalendarWidget I could custom code, but I’m tight for time so I just have the Advanced List Widget link over to the filtered calendar by category. Good enough.
March 18, 2013 at 5:46 pm #43218Barry
MemberGreat – the main thing is you’ve got a solution in place 🙂
Do let us know if there you need any other support on this one though, otherwise I will close the thread a few days from now.
-
AuthorPosts
- The topic ‘Use the_widget for Event Tribe Widgets with arguments’ is closed to new replies.
