Plugin Directory

Changeset 3469257


Ignore:
Timestamp:
02/25/2026 09:41:19 AM (5 weeks ago)
Author:
forge12
Message:

3.6.0

Moved consent export to Pro plugin. The export UI and AJAX endpoint are no longer available without the Pro plugin.
Added f12_doi_database_page_after_forms hook for extensibility. Safe to update.

Location:
double-opt-in/trunk
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • double-opt-in/trunk/CF7DoubleOptIn.class.php

    r3465646 r3469257  
    1616     * Text Domain: double-opt-in
    1717     * Domain Path: /languages
    18      * Version: 3.5.0
     18     * Version: 3.6.0
    1919     * Author: Forge12 Interactive GmbH
    2020     * Author URI: https://www.forge12.com
    2121     */
    2222    if ( ! defined( 'FORGE12_OPTIN_VERSION' ) ) {
    23         define( 'FORGE12_OPTIN_VERSION', '3.5.0' );
     23        define( 'FORGE12_OPTIN_VERSION', '3.6.0' );
    2424    }
    2525    if ( ! defined( 'FORGE12_OPTIN_SLUG' ) ) {
  • double-opt-in/trunk/Readme.txt

    r3465646 r3469257  
    66Tested up to: 6.9
    77Requires PHP: 8.0
    8 Stable tag: 3.5.0
     8Stable tag: 3.6.0
    99License: GPLv3
    1010License URI: http://www.gnu.org/licenses/gpl-3.0.html
     
    234234== Upgrade Notice ==
    235235
     236= 3.6.0 =
     237Moved consent export to Pro plugin. The export UI and AJAX endpoint are no longer available without the Pro plugin.
     238Added `f12_doi_database_page_after_forms` hook for extensibility. Safe to update.
     239
    236240= 3.5.0 =
    237241Fixed confirmation mail not being sent for forms with Quiz, Acceptance, or required fields.
     
    266270
    267271== Changelog ==
     272
     273= 3.6.0 =
     274
     275**Architecture:**
     276
     277* Moved: Consent export (CSV/JSON) is now a Pro-only feature. The `ConsentExportController` and `ConsentExportService` have been removed from the free plugin and moved to the Pro plugin.
     278* Security: The `doi_export_consent` AJAX endpoint is no longer registered in the free plugin, preventing unauthorized access without a Pro license.
     279* New: Added `f12_doi_database_page_after_forms` action hook on the Database admin page, allowing extensions to render additional UI after the built-in database management forms.
    268280
    269281= 3.5.0 =
  • double-opt-in/trunk/src/Providers/GdprServiceProvider.php

    r3449693 r3469257  
    99namespace Forge12\DoubleOptIn\Providers;
    1010
    11 use Forge12\DoubleOptIn\Admin\ConsentExportController;
     11use Forge12\DoubleOptIn\Admin\SingleConsentExportController;
    1212use Forge12\DoubleOptIn\Container\BootableProviderInterface;
    1313use Forge12\DoubleOptIn\Container\Container;
    1414use Forge12\DoubleOptIn\Repository\OptInRepositoryInterface;
    15 use Forge12\DoubleOptIn\Service\ConsentExportService;
    1615use Forge12\DoubleOptIn\Service\PrivacyIntegration;
    1716use Forge12\Shared\LoggerInterface;
     
    3231     */
    3332    public function register( Container $container ): void {
    34         $container->singleton( ConsentExportService::class, function ( Container $c ) {
    35             return new ConsentExportService(
     33        $container->singleton( PrivacyIntegration::class, function ( Container $c ) {
     34            return new PrivacyIntegration(
    3635                $c->get( LoggerInterface::class ),
    3736                $c->get( OptInRepositoryInterface::class )
     
    3938        } );
    4039
    41         $container->singleton( ConsentExportController::class, function ( Container $c ) {
    42             return new ConsentExportController(
    43                 $c->get( LoggerInterface::class ),
    44                 $c->get( ConsentExportService::class )
    45             );
    46         } );
    47 
    48         $container->singleton( PrivacyIntegration::class, function ( Container $c ) {
    49             return new PrivacyIntegration(
     40        $container->singleton( SingleConsentExportController::class, function ( Container $c ) {
     41            return new SingleConsentExportController(
    5042                $c->get( LoggerInterface::class ),
    5143                $c->get( OptInRepositoryInterface::class )
     
    5850     */
    5951    public function boot( Container $container ): void {
    60         // Register AJAX actions for consent export
    61         $container->get( ConsentExportController::class )->registerActions();
    62 
    6352        // Register WordPress Privacy Tools hooks
    6453        $container->get( PrivacyIntegration::class )->register();
     54
     55        // Register single-record consent export (fallback if Pro is not active)
     56        $container->get( SingleConsentExportController::class )->registerActions();
    6557    }
    6658}
  • double-opt-in/trunk/ui/UIDatabase.class.php

    r3449693 r3469257  
    207207            </form>
    208208
    209             <?php if ( apply_filters( 'f12_doi_is_pro_active', false ) ) : ?>
    210             <hr>
    211             <h2><?php _e( 'Export Consent Records (GDPR)', 'double-opt-in' ); ?></h2>
    212             <p><?php _e( 'Export consent records for GDPR compliance documentation.', 'double-opt-in' ); ?></p>
    213             <form action="<?php echo esc_url( admin_url( 'admin-ajax.php' ) ); ?>" method="post" target="_blank">
    214                 <input type="hidden" name="action" value="doi_export_consent">
    215                 <?php wp_nonce_field( 'doi_consent_export' ); ?>
    216 
    217                 <div class="option">
    218                     <div class="label">
    219                         <label for="doi-export-format"><?php _e( 'Format', 'double-opt-in' ); ?></label>
    220                     </div>
    221                     <div class="input">
    222                         <select name="format" id="doi-export-format">
    223                             <option value="csv">CSV</option>
    224                             <option value="json">JSON</option>
    225                         </select>
    226                     </div>
    227                 </div>
    228 
    229                 <div class="option">
    230                     <div class="label">
    231                         <label for="doi-export-scope"><?php _e( 'Scope', 'double-opt-in' ); ?></label>
    232                     </div>
    233                     <div class="input">
    234                         <select name="scope" id="doi-export-scope">
    235                             <option value="all"><?php _e( 'All Records', 'double-opt-in' ); ?></option>
    236                             <option value="email"><?php _e( 'By Email', 'double-opt-in' ); ?></option>
    237                         </select>
    238                     </div>
    239                 </div>
    240 
    241                 <div class="option" id="doi-export-email-field" style="display:none;">
    242                     <div class="label">
    243                         <label for="doi-export-email"><?php _e( 'Email', 'double-opt-in' ); ?></label>
    244                     </div>
    245                     <div class="input">
    246                         <input type="email" name="email" id="doi-export-email" class="regular-text" placeholder="user@example.com">
    247                     </div>
    248                 </div>
    249 
    250                 <div class="option">
    251                     <div class="label"></div>
    252                     <div class="input">
    253                         <input type="submit" class="button button-primary" value="<?php esc_attr_e( 'Export', 'double-opt-in' ); ?>">
    254                     </div>
    255                 </div>
    256             </form>
    257             <script>
    258                 (function() {
    259                     var scopeSelect = document.getElementById('doi-export-scope');
    260                     var emailField = document.getElementById('doi-export-email-field');
    261                     if (scopeSelect && emailField) {
    262                         scopeSelect.addEventListener('change', function() {
    263                             emailField.style.display = this.value === 'email' ? '' : 'none';
    264                         });
    265                     }
    266                 })();
    267             </script>
    268             <?php endif; ?>
     209            <?php do_action( 'f12_doi_database_page_after_forms' ); ?>
    269210            <?php
    270211            $this->get_logger()->notice('Database management page content rendered successfully.', [
Note: See TracChangeset for help on using the changeset viewer.