Add consent reopener: floating widget + anchor link trigger
Allow visitors to reopen the cookie preferences modal after making their choice via a configurable floating button (bottom-right or right-side vertical) or any anchor link with href="#att-cc-preferences". Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -164,6 +164,12 @@ class ATT_Consent_Admin {
|
||||
$settings['consent_mode'] = in_array( $_POST['consent_mode'] ?? '', array( 'advanced', 'basic' ), true ) ? $_POST['consent_mode'] : 'advanced';
|
||||
$settings['banner_position'] = in_array( $_POST['banner_position'] ?? '', array( 'bottom', 'top', 'center' ), true ) ? $_POST['banner_position'] : 'bottom';
|
||||
$settings['consent_expiry'] = absint( $_POST['consent_expiry'] ?? 365 );
|
||||
$settings['floating_widget'] = in_array(
|
||||
$_POST['floating_widget'] ?? '',
|
||||
array( 'bottom-right', 'right', 'none' ),
|
||||
true
|
||||
) ? $_POST['floating_widget'] : 'bottom-right';
|
||||
$settings['floating_widget_label'] = sanitize_text_field( $_POST['floating_widget_label'] ?? '' );
|
||||
break;
|
||||
|
||||
case 'appearance':
|
||||
|
||||
Reference in New Issue
Block a user