WordPress.org

Ready to get started?Download WordPress

Forums

Codemirror 2 editor for WordPress admin area
[Plugin: Codemirror 2 editor for WordPress admin area] PHP 5.3 required ... (1 post)

  1. ixiter
    Member
    Posted 1 year ago #

    since you use function(){} as parameter.

    5.2.x users have to replace the code in codemirror-2.php by this code.

    <?php
    /*
    Plugin Name: Codemirror 2 editor
    Version: 0.1
    Author: Björn Ali Göransson
    Author URI: http://www.bedr.se/
    */
    
    function cm2_admin_enqueue_scripts(){
    	wp_enqueue_script("codemirror_1", "/wp-content/plugins/codemirror-2/scripts/codemirror-compressed.js", array("jquery"));
    	wp_enqueue_script("codemirror_2", "/wp-content/plugins/codemirror-2/scripts/main.js", array("jquery"));
    	wp_enqueue_style("codemirror_1", "/wp-content/plugins/codemirror-2/styles/codemirror.css");
    	wp_enqueue_style("codemirror_2", "/wp-content/plugins/codemirror-2/styles/main.css");
    }
    
    add_action('admin_enqueue_scripts', 'cm2_admin_enqueue_scripts');

    anyway .. great plugin. Thanks. 5 Stars!

    http://wordpress.org/extend/plugins/codemirror-2/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic