Accordion Upcoming with Geo Location

Accordion Upcoming Events with Geo Location

In order to use the GeoLocation in Accordion Upcoming Events, you will need to install the GeoIP Detection plugin.

feed: 0 will not show the feeds from External Event Sources and 1 will include the feeds.
auw_title_type: 1 will not render the Event Title as a link.
hierarchical_filter=”0″
taxonomy: This is the taxonomy you want to use to filter. The defaults are Calendar, Venue, and Organizer, but you can also use any custom taxonomy you have created.
terms: This is the parent term you want to use.
terms_children: 1 will show the child terms of the parent.
tax_filter_multiple: 1 will allow to select multiple terms in drop down. 0 will only allow selecting one term in drop down.
geo_radius: Choose either Miles or Kilometer in Options > General Settings and then enter the radius you want to set for showing events.
geo_center:  This is the Latitude and Longitude that can be used to set a fixed location. If you do not set this the Geo IP plugin will detect the visitor’s location.

Your location based on GeoIP
IP of the user: 54.80.137.187
Country: United States
State or region: Virginia
City: Ashburn

Data from: GeoLite2 City database (updated monthly)

In the first example below we have used the geo_center attribute to set a fixed Latitude and Longitude as if you are in Hoboken, NJ (5 minutes from Manhattan, NY).

[rhc_static_upcoming_events template="widget_custom_accordion.php" number="10" header="btn_tax_calendar,btn_tax_organizer" horizon="hour" words="100" date_format="MMM d, yyyy" time_format="h:mmtt" order="ASC" post_type="events" showimage="1" feed="0" nav="1" auw_title_type="1" hierarchical_filter="1" taxonomy="calendar" terms="obstacle-racing" terms_children="1" terms_hide_empty="1" tax_filter_multiple="0" geo_radius="500" geo_center="40.753118, -74.024485" no_events_message="Sorry, but there are no events within 500 miles (800 kilometers) from your location."]

In the example below, we have not used geo_center attribute to set a fixed Latitude and Longitude.

The GeoIP Detection plugin will detect your location and the Accordion Upcoming Events will show events within 500 miles (800 kilometers) from your location. If you are outside the radius set you will see the no events message.

[rhc_static_upcoming_events template="widget_custom_accordion.php" number="10" header="btn_tax_calendar,btn_tax_organizer" horizon="hour" words="100" date_format="MMM d, yyyy" time_format="h:mmtt" order="ASC" post_type="events" showimage="1" feed="0" nav="1" auw_title_type="1" hierarchical_filter="1" taxonomy="calendar" terms="obstacle-racing" terms_children="1" terms_hide_empty="1" tax_filter_multiple="0" geo_radius="500" geo_center="" no_events_message="Sorry, but there are no events within 500 miles (800 kilometers) from your location."]