=== GDPR-Extensions-com - Youtube 2xClick Solution ===

Contributors: gdprextensionscom
Tags: YouTube, GDPR, Privacy, Video, Embed
Requires at least: 6.4
Tested up to: 6.8
Stable tag: 1.0.1
Requires PHP: 8.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Short Description:
The GDPR YouTube 2xClick Solution lets you embed YouTube videos while protecting user privacy through consent-based loading.


=== Description ===
The **YouTube 2xClick Solution** by GDPR-Extensions.com is a privacy-first plugin that allows you to embed YouTube videos in a GDPR-compliant manner. By default, videos are hidden behind a customizable content mask and only activated after the user consents to the use of YouTube cookies.

Key features include:
- Consent-based embedding with customizable overlay.
- No YouTube cookies until user approval.
- Integration with cookie consent managers or standalone usage.
- Custom player settings (autoplay, loop, controls).


=== Installation ===
1. Upload the plugin files to the `/wp-content/plugins/gdpr-extensions-com-youtube-2xclick-solution` directory, or install via the WordPress plugin repository.
2. Activate the plugin through the 'Plugins' menu in WordPress.
3. Go to `Settings > YouTube 2xClick` to customize the content mask and player behavior.

To embed a video:
- Use the shortcode:  
  `[youtube_2xclick url="https://www.youtube.com/watch?v=example123"]`

- Optional attributes:  
  `autoplay="1"`, `loop="1"`, `controls="0"`


=== Features and Customization ===
Content Mask Customization:  
- Choose a background color or upload a custom image.  
- Edit the overlay text (e.g., “To watch this video, please allow cookies from YouTube.”).

Consent Workflow:  
- With consent manager: YouTube cookies are listed and require approval before the video is loaded.  
- Without consent manager: Consent is collected directly from the overlay.

Player Configuration:  
- Control autoplay, loop, and visibility of player controls.  
- Multiple YouTube videos can be embedded per page.

=== Data Handling Policy ===
Objective:  
To ensure full GDPR compliance through transparent and minimal data usage.

== YouTube Embedding ==

Purpose: Embed videos in a privacy-friendly way without preloading external resources.

Data Sent: No cookies or external YouTube connections until user approval.

Data Storage: Cookies are only stored after consent and expire after 30 days. No persistent data is stored by the plugin.

Consent Options

= With Consent Manager:=
- Consent is requested and managed via your site’s cookie manager.

= Without Consent Manager: =
- Consent is obtained directly via the plugin’s content mask.

= Security and User Control: =
- No automatic data sharing.
- Users control when and how cookies are created.
- No third-party scripts load without consent.


=== How to Use ===
1. Install and activate the plugin.  
2. Navigate to `Settings > YouTube 2xClick` to configure appearance and behavior.  
3. Use the shortcode `[youtube_2xclick url="VIDEO_URL"]` in any post, page, or widget.  
4. Customize player and consent options using shortcode attributes.

=== External Service Details ===
This plugin connects to YouTube only after users explicitly opt-in. All calls and cookies are disabled by default, ensuring compliance with GDPR, ePrivacy, and privacy-focused web development standards.

=== Developer Notes ===
Prefix for functions and database entries: `gdprextensionscomyt2x`  
Built with WordPress best practices and compatibility in mind.

=== Privacy Policy  ===
The YouTube 2xClick Solution by GDPR-Extensions.com is designed to respect user privacy and ensure full compliance with GDPR and related data protection laws.

= What Data Is Collected: =
- By default, no personal data is collected or stored by the plugin.
- YouTube videos and cookies are only loaded after explicit user consent.

= How Consent Is Handled: =
- When a consent management system is active, this plugin defers cookie handling to that system.
- Without a consent manager, users must interact with a content mask to enable cookies. No YouTube scripts or tracking are triggered before consent.

= Cookie Information: =
- YouTube cookies (e.g., VISITOR_INFO1_LIVE, YSC, and others) are only created after the user consents.
- Default cookie expiration is 30 days unless modified by YouTube.

= Data Sharing: =
- No user data is sent to GDPR-Extensions.com.
- No third-party data sharing occurs without user action.

= Security: =
- The plugin avoids preloading third-party scripts and follows WordPress security best practices.

= Your Control: =
- Users may revoke consent at any time via your site’s cookie management tools.
- Admins may remove or reset embedded videos to reset consent behavior.

For more information, review:
- https://policies.google.com/privacy
- https://policies.google.com/terms
-[GDPR-Extensions.com Terms](https://www.gdpr-extensions.com/gdpr-solutions/our-2-click-solutions/youtube-2xclick-solution/terms-of-use)
-[GDPR-Extensions.com Privacy Policy](https://www.gdpr-extensions.com/gdpr-solutions/our-2-click-solutions/youtube-2xclick-solution/privacy-policy)

=== Frequently Asked Questions (FAQ) ===
**How does this plugin block YouTube cookies?**  
Until consent is given, YouTube is not loaded, preventing any cookie creation or tracking.

**Do I need a consent manager?**  
No. The plugin works standalone or integrates with existing consent management tools.

**Can I style the content mask?**  
Yes, through the plugin settings you can customize background image, color, and text.

**What happens after the user consents?**  
The content mask is removed, the YouTube video is loaded, and cookies are created.

== Developer Notes ==
This plugin uses the 'gdprextensioncomyt' prefix for function names and database tables to ensure uniqueness and avoid conflicts with other plugins.

== Upgrade Notice ==
= 1.0.0 =
* Initial release

= 1.0.1 =
* **Security Improvements:** Addressed vulnerabilities identified in the previous version and enhanced overall security.
* **Bug Fixes:** Resolved minor issues affecting the functionality and performance of the plugin.
* **New Customization Options:** Added new options for customizing the **GDPR YouTube 2xClick Solution**, giving users more control over layout, style, and text.
* **Code Refactoring:** Optimized codebase for better performance and compatibility.


=== Contact ===
For questions or support, reach out to us at support@gdpr-extensions.com.