PluginProbe
Code Engine – PHP Snippets, AI Functions & Automation for WordPress / 0.2.8
Code Engine – PHP Snippets, AI Functions & Automation for WordPress v0.2.8
0.5.6 0.5.5 0.5.4 0.5.3 0.5.2 0.5.1 0.5.0 0.4.9 0.4.8 0.4.7 0.4.6 trunk 0.0.1 0.0.2 0.2.8 0.2.9 0.3.0 0.3.1 0.3.2 0.3.3 0.3.4 0.3.5 0.3.6 0.3.7 0.3.8 All 32 releases
code-engine / constants / init.php

init.php in Code Engine – PHP Snippets, AI Functions & Automation for WordPress 0.2.8, at constants/init.php

18 lines 556 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if ( ! defined( 'ABSPATH' ) ) exit;
4
5 define( 'CDEGN_OPTIONS', [] );
6
7 function cdegn_enqueue_scripts( ) {
8 $screen = get_current_screen();
9 if ( $screen->id === 'settings_page_cdegn_settings' ) {
10 wp_register_script( 'code-engine', CDEGN_URL . 'js/code-engine.js', [], CDEGN_VERSION, true );
11 wp_enqueue_script( 'code-engine' );
12 wp_localize_script( 'code-engine', 'code_engine', [
13 'rest_url' => rest_url( 'code-engine/v1' ),
14 ]);
15 }
16 }
17
18 add_action( 'admin_enqueue_scripts', 'cdegn_enqueue_scripts' );