Description
The “PressHero Amelia Bookings Shortcode Addon” plugin is a custom extension for the Amelia Booking plugin in WordPress. It enhances the default shortcode functionality of the Amelia Booking plugin by adding two new attributes: eventCount and hideFull. These attributes allow users to control the number of events displayed in the events list and to hide fully booked events, respectively.
Features:
- Limit Event Display: The
eventCountattribute lets users specify the maximum number of events to display in the list. - Hide Fully Booked Events: The
hideFullattribute enables users to hide events that are fully booked, providing a cleaner and more relevant events list.
Detailed Functionality:
- Event Count Limiting:
- The
eventCountattribute takes an integer value which specifies the maximum number of events to display. - Example:
[ameliaeventslistbookingcustom eventCount="5"]will display a maximum of 5 events.
- The
- Hide Fully Booked Events:
- The
hideFullattribute takes a boolean value (trueorfalse). When set totrue, fully booked events will be hidden from the events list. - Example:
[ameliaeventslistbookingcustom hideFull="true"]will hide all fully booked events from the list.
- The
- Combined Usage:
- Both attributes can be used together to limit the number of events displayed and hide fully booked events simultaneously.
- Example:
[ameliaeventslistbookingcustom eventCount="5" hideFull="true"]will display up to 5 events, excluding any that are fully booked.
How It Works:
- The plugin checks if the Amelia plugin is active. If not, it displays an admin notice prompting the user to activate the Amelia plugin.
- If the Amelia plugin is active, it registers a custom shortcode
[ameliaeventslistbookingcustom]. - The shortcode handler processes the attributes provided, merges them with default values, and prepares the necessary scripts and styles.
- The events list is rendered, and custom JavaScript is added to manipulate the displayed events based on the
eventCountandhideFullattributes.
Shortcode Examples:
- Limit to 3 Events:
[ameliaeventslistbookingcustom eventCount=”3″]
- This shortcode will display a maximum of 3 events.
- Hide Fully Booked Events:
[ameliaeventslistbookingcustom hideFull=”true”]
- This shortcode will hide any events that are fully booked.
- Limit to 5 Events and Hide Fully Booked:
[ameliaeventslistbookingcustom eventCount=”5″ hideFull=”true”]
- This shortcode will display a maximum of 5 events, excluding any that are fully booked.





Reviews
There are no reviews yet.