| @@ -149,11 +149,9 @@ | ||
| 149 | 149 | echo $content; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped |
| 150 | 150 | return; |
| 151 | 151 | } |
| 152 | 152 | |
| 153 | -// If hide_form is enabled and not unlocked, show nothing (or just the content for cookie-based access). | |
| 154 | 153 | if ( $advanced_options && $hide_form ) { |
| 155 | - echo $content; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped | |
| 156 | 154 | return; |
| 157 | 155 | } |
| 158 | 156 | |
| 159 | 157 | // Get global options for form defaults. |
| @@ -229,11 +227,8 @@ | ||
| 229 | 227 | |
| 230 | 228 | // ACF placeholder (not used in blocks). |
| 231 | 229 | $form = str_replace( '[PASSSTER_ACF]', '', $form ); |
| 232 | 230 | |
| 233 | -// Store content for JS to reveal after unlock. | |
| 234 | -$content_encoded = base64_encode( $content ); | |
| 235 | - | |
| 236 | 231 | // Wrapper classes. |
| 237 | 232 | $wrapper_classes = array( 'passster-protected-content', 'wp-block-passster-protected-content' ); |
| 238 | 233 | if ( ! empty( $attributes['align'] ) ) { |
| 239 | 234 | $wrapper_classes[] = 'align' . $attributes['align']; |
| @@ -262,9 +257,7 @@ | ||
| 262 | 257 | <?php endforeach; ?> |
| 263 | 258 | > |
| 264 | 259 | <div class="passster-protected-content__form"> |
| 265 | 260 | <?php echo $form; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> |
| 266 | - </div> | |
| 267 | - <div class="passster-protected-content__content" style="display: none;" data-content="<?php echo esc_attr( $content_encoded ); ?>"> | |
| 268 | 261 | </div> |
| 269 | 262 | </div> |
| 270 | 263 | <?php |