Appearance -> Custom Codes after installing the plugin. * Version: 3.5 * Author: Saifudheen Mak * Author URI: https://maktalseo.com * License: GPL2 * Text Domain: add-custom-codes */ add_action( 'init', 'accodes_load_textdomain' ); function accodes_load_textdomain() { load_plugin_textdomain( 'add-custom-codes', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' ); } /*--------------------------------- styles and scripts for plugin page -----------------------------------------*/ add_action('admin_enqueue_scripts', 'codemirror_enqueue_scripts'); function codemirror_enqueue_scripts($hook) { $cm_settings['codeEditor'] = wp_enqueue_code_editor(array('type' => 'htmlmixed')); wp_localize_script('jquery', 'cm_settings', $cm_settings); wp_enqueue_script('wp-theme-plugin-editor'); wp_enqueue_style('wp-codemirror'); wp_register_style( 'add-custom-codes', plugins_url( 'add-custom-codes/css/styles.css' ), '', '3.5' ); wp_enqueue_style( 'add-custom-codes' ); wp_register_script( 'add-custom-codes1', plugins_url( 'add-custom-codes/js/script.js' ), '', '3.5' ); wp_enqueue_script( 'add-custom-codes1' ); } /*------------------------------ add menu icon ------------------------*/ add_action('admin_menu', 'accodes_menu'); function accodes_menu() { add_theme_page('Add Custom Codes', 'Custom Codes', 'administrator', 'add-custom-codes', 'accodes_settings_page'); } function accodes_settings_page() { ?>
Please donate something to support further development of this plugin and other new plugins that are on the way. You can choose how much to donate!