PluginProbe
Woody Code Snippets – Insert PHP, CSS, JS, and Header/Footer Scripts / 2.7.8
Woody Code Snippets – Insert PHP, CSS, JS, and Header/Footer Scripts v2.7.8
2.7.9 2.7.8 2.7.7 2.7.6 2.7.5 2.7.4 trunk 1.3 2.0.4 2.0.6 2.1.91 2.2.4 2.2.7 2.2.9 2.3.1 2.3.10 2.4.10 2.4.2 2.4.4 2.4.5 2.4.6 2.4.7 2.4.8 2.4.9 2.6.0 All 30 releases
← All changes | insert_php.php +28 -2 2.7.7 → 2.7.8 View file →
@@ -3,9 +3,9 @@
3 3 * Plugin Name: Woody Code Snippets
4 4 * Plugin URI: https://woodysnippet.com/
5 5 * Description: Executes PHP code, uses conditional logic to insert ads, text, media content and external service's code. Ensures no content duplication.
6 6 * Author: Themeisle
7 - * Version: 2.7.7
7 + * Version: 2.7.8
8 8 * WordPress Available: yes
9 9 * Requires License: no
10 10 * Text Domain: insert-php
11 11 * Domain Path: /languages/
@@ -40,9 +40,9 @@
40 40
41 41 // Set the constant that the plugin is activated.
42 42 define( 'WINP_PLUGIN_ACTIVE', true );
43 43
44 -define( 'WINP_PLUGIN_VERSION', '2.7.7' );
44 +define( 'WINP_PLUGIN_VERSION', '2.7.8' );
45 45
46 46 // Root directory of the plugin.
47 47 define( 'WINP_PLUGIN_DIR', __DIR__ );
48 48
@@ -244,8 +244,33 @@
244 244 ];
245 245 }
246 246
247 247 /**
248 + * AI Connect metadata.
249 + *
250 + * Only the read abilities are listed: the abilities that save or activate
251 + * snippets run code, so the site owner switches those on deliberately.
252 + *
253 + * @return array<string, mixed>
254 + */
255 +function winp_sdk_ai_connect() {
256 + return [
257 + 'name' => 'Woody Code Snippets',
258 + 'notice_cases' => [
259 + __( 'find where a script is inserted', 'insert-php' ),
260 + __( 'review the code of a snippet', 'insert-php' ),
261 + __( 'audit your active snippets', 'insert-php' ),
262 + ],
263 + 'prompts' => [
264 + __( 'Find which Woody Code Snippets load gtag and where they are inserted.', 'insert-php' ),
265 + __( 'Show me the code of my header scripts snippet and explain what it does.', 'insert-php' ),
266 + __( 'Which of my snippets run PHP on every page?', 'insert-php' ),
267 + ],
268 + 'ability_prefix' => 'woody',
269 + ];
270 +}
271 +
272 +/**
248 273 * Register compatibility using SDK.
249 274 *
250 275 * @param array<string, array<string, string>> $compatibilities All compatibilities.
251 276 *
@@ -261,8 +286,9 @@
261 286 }
262 287
263 288 add_filter( 'themeisle_sdk_products', 'winp_sdk_register_products' );
264 289 add_filter( WINP_PLUGIN_NAMESPACE . '_about_us_metadata', 'winp_sdk_about_page' );
290 +add_filter( WINP_PLUGIN_NAMESPACE . '_ai_connect_metadata', 'winp_sdk_ai_connect' );
265 291 add_filter( 'themeisle_sdk_compatibilities/' . basename( WINP_PLUGIN_DIR ), 'winp_sdk_register_compatibility' );
266 292
267 293 // Register activation/deactivation hooks.
268 294 register_activation_hook(