=== EventBookings ===
Contributors: eventbookings
Tags: events, event plugin, event display, event integration, eventbookings
Requires at least: 5.0
Tested up to: 7.1
Requires PHP: 7.2
Stable tag: 1.6.3
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

A powerful plugin to fetch and display event data from EventBookings on your WordPress site.

== Description ==

**EventBookings Event Plugin** is a powerful WordPress plugin designed to seamlessly fetch and display event data from EventBookings. With this plugin, you can easily integrate and showcase upcoming events on your WordPress site, providing users with real-time event details.

**Key features include:**
- Automatic fetching of upcoming events from EventBookings
- User-friendly display options with responsive layouts
- Easy integration using shortcodes
- Customization settings from the WordPress admin panel

== Installation ==

1. Download the EventBookings Event Plugin from the WordPress Plugin Directory.
2. Upload the plugin to your WordPress site via the Plugins > Add New section.
3. Activate the plugin through the ‘Plugins’ menu in WordPress.
4. Configure settings under the **EventBookings Event Plugin** menu.
5. Use the provided shortcode to display events on any page or post.

== Frequently Asked Questions ==

= How do I display events on my website? =
Use the provided shortcode `[eventbookings_events]` in any post, page, or widget.

= Do I need an EventBookings account? =
Yes, you’ll need an account with EventBookings and an API key to fetch event data.

= Is the plugin customizable? =
Yes, you can configure display settings through the admin panel.

== External Services ==

This plugin connects to the following third-party services:

- Google Maps API (maps.googleapis.com) for interactive map and location features.
- YouTube (youtube.com, img.youtube.com) for displaying video thumbnails.
- EventBookings Public API (event-api.com) for retrieving and managing event data.

= Google Maps API =
Used to display interactive maps, autocomplete addresses, and embed map previews on event pages.
Data sent: When users view pages containing maps or address fields, their browser connects directly to Google’s servers. This may include the user’s IP address, browser information, and location input.
Terms of Service: https://maps.google.com/help/terms_maps/
Privacy Policy: https://policies.google.com/privacy

= YouTube =
Used to display video thumbnails and previews for events.
Data sent: When a thumbnail or embedded video is displayed, the user’s browser requests the image or video file directly from YouTube servers. This may include the user’s IP address and browser information.
Terms of Service: https://www.youtube.com/t/terms
Privacy Policy: https://policies.google.com/privacy

= EventBookings Public API =
Used to fetch and display event information (titles, descriptions, dates, locations, ticket availability) and handle event bookings.
Data sent:
- When viewing event listings: Event/location queries are sent from your site to the EventBookings API.
- When registering/purchasing tickets: User data required for booking (such as name, email, ticket selection, and payment details) is transmitted securely to the EventBookings API.
- EventBookings Terms of Service: https://www.eventbookings.com/terms-conditions-for-ticket-sellers/
- EventBookings Privacy Policy: https://www.eventbookings.com/privacy-policy/


== External Assets ==

This plugin loads the following external files for proper functionality:

- CSS preload: https://cdnjs.cloudflare.com/ajax/libs/loadCSS/2.0.1/cssrelpreload.min.js
- MutationObserver shim: https://cdn.jsdelivr.net/npm/mutationobserver-shim/dist/mutationobserver.min.js
- Polyfill fetch: https://unpkg.com/unfetch/polyfill
- Formeo sprite: https://draggable.github.io/formeo/assets/img/formeo-sprite.svg

These files are required by Formeo and are loaded from third-party CDNs.

= EventBookings API =

=== What the service is and what it is used for ===
The EventBookings API (https://api-rto.eventbookings.com) is used to fetch live event data, process ticket purchases, and manage bookings directly from your WordPress site. This ensures that event details, availability, and booking statuses are always current.

=== What data is sent and when ===
- **When viewing events:** The plugin sends your EventBookings account API key to retrieve event details, including event title, description, dates, and ticket availability.
- **When purchasing tickets:** The plugin sends the purchaser's name, email address, selected event ID, ticket quantity, and payment information directly to the EventBookings API for processing.
- **When managing bookings:** If an admin or user updates booking details, relevant booking IDs and updated fields are sent to the API.

=== Where data is sent ===
All data is securely transmitted over HTTPS to the EventBookings API at https://api-rto.eventbookings.com.

=== Conditions for sending data ===
Data is only sent when:
1. A page containing the event shortcode/widget is loaded (to fetch event details).
2. A user completes the checkout form (to purchase tickets).
3. An admin or user updates booking information.
A valid EventBookings account and API key are required for these actions.

=== Terms and Privacy ===
Before using this plugin, please review:
- EventBookings Terms of Service: https://www.eventbookings.com/terms-conditions-for-ticket-sellers/
- EventBookings Privacy Policy: https://www.eventbookings.com/privacy-policy/

== Screenshots ==

1. Settings page for API configuration.
2. Example event listing on a WordPress page.
3. Responsive event layout.

== Changelog ==

= 1.6.3 =
* **Update**: Refreshed frontend component bundle (dist/component-bundle.js)
* **Compatibility**: Tested up to WordPress 7.1
* **Assets**: Frontend and admin CSS/JS cache-busted to version 1.6.3

= 1.6.2 =
* **Update**: Refreshed frontend component bundle with minor JS improvements
* **Update**: Added Requires at least, Tested up to, and Requires PHP headers to main plugin file

= 1.6.1 =
* **Bug Fix**: Rebuilt and updated frontend component bundle (dist/component-bundle.js)

= 1.6 =
* **UI Redesign**: Completely rebuilt the Settings page with a modern card-based layout
* **UI**: Connection Settings, Shortcodes, and Customize Event Display each presented in clean, bordered cards with icon headers
* **UI**: Animated "Connected" status badge with pulsing indicator when API credentials are active
* **UI**: Shortcode copy buttons now use the Clipboard API with a visual "✓ Copied" confirmation state
* **UI**: Custom checkbox grid replaces the plain table for event display options
* **UI**: Inline success/error notices replace the generic WordPress admin banners
* **Assets**: Admin CSS and JS cache-busted to version 1.6

= 1.0 =
* Initial release with shortcode support and event API integration.

= 1.1 =
* Added feature event support and feature events slider.

= 1.2 =
* Order nonce issue fixed
* Event details map issue fixed

= 1.5 =
* **Bug Fix**: Fixed `customized_settings` returning stale data due to overly aggressive Cache-Control header in event details AJAX handler
* **Bug Fix**: Fixed boolean cast corrupting non-boolean DB columns (`id`, `organisation_uuid`) in customized settings response
* **New Feature**: Added Clear Cache button to Settings page to manually flush the EventBookings object cache

= 1.4 =
* **Frontend**: Rebuilt component bundle with latest source changes
* **Assets**: Refreshed jQuery UI icon sprites across all colour variants
* **Config**: Updated JS configuration for v1.4
* **Docs**: Added Google Maps API setup guide
* **Build**: Added `.gitignore` to exclude dist build artifacts from version control

= 1.3 =
* **Security Enhancement**: Fixed unsanitized POST parameter vulnerability in event details AJAX handler
* **Security Enhancement**: Added proper wp_unslash() to GET parameter handling
* **Build Optimization**: Configured conditional source maps (development only, disabled in production)
* **Build Optimization**: Added separate npm scripts for production and development builds
* **Developer Tools**: Added comprehensive build documentation (BUILD.md)
* **Code Quality**: Improved webpack configuration with environment-based optimization

== Upgrade Notice ==

= 1.6.3 =
* Frontend component bundle update and WordPress 7.1 compatibility. No database changes — safe to update.

= 1.6.2 =
* Minor JS update and plugin header improvements. No database changes — safe to update.

= 1.6.1 =
* Frontend component bundle update. No database changes — safe to update.

= 1.6 =
* Settings page has been fully redesigned. No database changes — safe to update.

= 1.0 =
First stable release.

= 1.1 =
* Added feature event support and feature events slider.

= 1.2 =
* Order nonce issue fixed
* Event details map issue fixed

= 1.5 =
* Fixes stale customized settings in event detail pages. Recommended update for all users.

= 1.4 =
* Frontend asset refresh and build tooling update.

= 1.3 =
* Important security and build optimization improvements. Recommended update for all users.

== License ==

This plugin is licensed under the GPLv2 or later.
