Changeset 3474794
- Timestamp:
- 03/04/2026 05:54:40 PM (4 weeks ago)
- Location:
- ai-discovery-files/trunk
- Files:
-
- 5 edited
-
admin/class-admin.php (modified) (1 diff)
-
admin/views/partials/verify-modal.php (modified) (1 diff)
-
ai-discovery-files.php (modified) (2 diffs)
-
includes/class-server.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
ai-discovery-files/trunk/admin/class-admin.php
r3472434 r3474794 245 245 $code = isset( $_POST['verify_code'] ) ? sanitize_text_field( wp_unslash( $_POST['verify_code'] ) ) : ''; 246 246 247 // Validate: must match "ai-visibility-verify=" followed by hex, or empty to clear. 248 if ( '' !== $code && ! preg_match( '/^ai-visibility-verify=[a-f0-9]+$/i', $code ) ) { 249 wp_send_json_error( __( 'Invalid verification code. The code should be in the format: ai-visibility-verify=abc123', 'ai-discovery-files' ) ); 247 // Strip the prefix if pasted — we only store the hex token. 248 $code = preg_replace( '/^ai-visibility-verify=/i', '', $code ); 249 250 // Validate: must be hex characters only, or empty to clear. 251 if ( '' !== $code && ! preg_match( '/^[a-f0-9]+$/i', $code ) ) { 252 wp_send_json_error( __( 'Invalid verification code. Paste the code shown in your directory dashboard.', 'ai-discovery-files' ) ); 250 253 } 251 254 -
ai-discovery-files/trunk/admin/views/partials/verify-modal.php
r3472434 r3474794 108 108 class="aidf-verify-modal__input" 109 109 value="<?php echo esc_attr( $verify_code ); ?>" 110 placeholder="<?php esc_attr_e( 'e.g. ai-visibility-verify=f1ade5505a308e39258ae94535be28a4', 'ai-discovery-files' ); ?>"110 placeholder="<?php esc_attr_e( 'e.g. f1ade5505a308e39258ae94535be28a4', 'ai-discovery-files' ); ?>" 111 111 spellcheck="false" 112 112 autocomplete="off"> -
ai-discovery-files/trunk/ai-discovery-files.php
r3472434 r3474794 4 4 * Plugin URI: https://www.ai-visibility.org.uk/wordpress-plugin/ai-discovery-files/ 5 5 * Description: Improve your AI Visibility by generating AI Discovery Files so AI systems like ChatGPT, Claude, and Gemini can correctly discover, interpret, and cite your website. 6 * Version: 1.1. 06 * Version: 1.1.1 7 7 * Requires at least: 6.2 8 8 * Requires PHP: 8.0 … … 24 24 * Plugin constants. 25 25 */ 26 define( 'AIDF_VERSION', '1.1. 0' );26 define( 'AIDF_VERSION', '1.1.1' ); 27 27 define( 'AIDF_PLUGIN_FILE', __FILE__ ); 28 28 define( 'AIDF_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); -
ai-discovery-files/trunk/includes/class-server.php
r3472434 r3474794 105 105 header( 'Cache-Control: no-store' ); 106 106 header( 'X-Robots-Tag: noindex' ); 107 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Plain text output, validated on save .107 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Plain text output, validated on save (hex only). 108 108 echo $verify_code; 109 109 exit; -
ai-discovery-files/trunk/readme.txt
r3473181 r3474794 5 5 Tested up to: 6.9 6 6 Requires PHP: 8.0 7 Stable tag: 1.1. 07 Stable tag: 1.1.1 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 168 168 == Changelog == 169 169 170 = 1.1.1 = 171 * Fix verification code input to accept just the token (auto-strips prefix if pasted) 172 * Serve only the bare token in ai-visibility-verify.txt 173 170 174 = 1.1.0 = 171 175 * Add domain verification for the AI Visibility Directory
Note: See TracChangeset
for help on using the changeset viewer.