Version Description
- Added compatibility for upcoming Wordpress 3.3 (currently beta 4)
- Added compatibility for previous Wordpress 3.0 and 3.1
- Optimization/compression of javascript code
Download this release
Release Info
Developer | marcochiesi |
Plugin | Black Studio TinyMCE Widget |
Version | 0.7 |
Comparing to | |
See all releases |
Code changes from version 0.6.5 to 0.7
- black-studio-tinymce-widget.css +9 -1
- black-studio-tinymce-widget.js +1 -92
- black-studio-tinymce-widget.php +61 -21
- readme.txt +20 -13
black-studio-tinymce-widget.css
CHANGED
@@ -3,6 +3,11 @@
|
|
3 |
#mce_fullscreen_container {
|
4 |
background-color: white;
|
5 |
}
|
|
|
|
|
|
|
|
|
|
|
6 |
.editor_container {
|
7 |
border-color: #CCC #CCC #DFDFDF;
|
8 |
border-style: solid;
|
@@ -52,8 +57,11 @@
|
|
52 |
}
|
53 |
.editor_media_buttons a {
|
54 |
cursor: pointer;
|
55 |
-
|
|
|
|
|
56 |
}
|
57 |
.editor_media_buttons img {
|
58 |
vertical-align: middle;
|
|
|
59 |
}
|
3 |
#mce_fullscreen_container {
|
4 |
background-color: white;
|
5 |
}
|
6 |
+
|
7 |
+
#wp-black-studio-tinymce-widget-wrap {
|
8 |
+
display: none;
|
9 |
+
}
|
10 |
+
|
11 |
.editor_container {
|
12 |
border-color: #CCC #CCC #DFDFDF;
|
13 |
border-style: solid;
|
57 |
}
|
58 |
.editor_media_buttons a {
|
59 |
cursor: pointer;
|
60 |
+
text-decoration: none;
|
61 |
+
color: #333;
|
62 |
+
font-size: 12px;
|
63 |
}
|
64 |
.editor_media_buttons img {
|
65 |
vertical-align: middle;
|
66 |
+
padding: 0 4px;
|
67 |
}
|
black-studio-tinymce-widget.js
CHANGED
@@ -1,92 +1 @@
|
|
1 |
-
|
2 |
-
function black_studio_activate_visual_editor(id) {
|
3 |
-
jQuery('#'+id).addClass("mceEditor");
|
4 |
-
if ( typeof( tinyMCE ) == "object" && typeof( tinyMCE.execCommand ) == "function" ) {
|
5 |
-
black_studio_deactivate_visual_editor(id);
|
6 |
-
tinyMCE.execCommand("mceAddControl", false, id);
|
7 |
-
}
|
8 |
-
}
|
9 |
-
// Deactivate visual editor
|
10 |
-
function black_studio_deactivate_visual_editor(id) {
|
11 |
-
if ( typeof( tinyMCE ) == "object" && typeof( tinyMCE.execCommand ) == "function" ) {
|
12 |
-
if (typeof(tinyMCE.get(id)) == "object") {
|
13 |
-
content = tinyMCE.get(id).getContent();
|
14 |
-
tinyMCE.execCommand("mceRemoveControl", false, id);
|
15 |
-
jQuery('textarea#'+id).val(content);
|
16 |
-
}
|
17 |
-
}
|
18 |
-
}
|
19 |
-
// Activate editor deferred (used upon opening the widget)
|
20 |
-
function black_studio_open_deferred_activate_visual_editor(id) {
|
21 |
-
jQuery('div.widget:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]').each(function() {
|
22 |
-
// If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
|
23 |
-
if (jQuery('div.widget:has(#' + id + ') :animated').size() == 0 && typeof(tinyMCE.get(id)) != "object" && jQuery('#' + id).is(':visible')) {
|
24 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=visual]', jQuery(this).parents('div.widget')).click();
|
25 |
-
}
|
26 |
-
// Otherwise wait and retry later (animation ongoing)
|
27 |
-
else if (typeof(tinyMCE.get(id)) != "object") {
|
28 |
-
setTimeout(function(){black_studio_open_deferred_activate_visual_editor(id);id=null;}, 100);
|
29 |
-
}
|
30 |
-
});
|
31 |
-
}
|
32 |
-
|
33 |
-
// Activate editor deferred (used upon ajax requests)
|
34 |
-
function black_studio_ajax_deferred_activate_visual_editor(id) {
|
35 |
-
jQuery('div.widget:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]').each(function() {
|
36 |
-
// If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
|
37 |
-
if (jQuery.active == 0 && typeof(tinyMCE.get(id)) != "object" && jQuery('#' + id).is(':visible')) {
|
38 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=visual]', jQuery(this).parents('div.widget')).click();
|
39 |
-
}
|
40 |
-
// Otherwise wait and retry later (animation ongoing)
|
41 |
-
else if (jQuery('div.widget:has(#' + id + ') div.widget-inside').is(':visible') && typeof(tinyMCE.get(id)) != "object") {
|
42 |
-
setTimeout(function(){black_studio_ajax_deferred_activate_visual_editor(id);id=null;}, 100);
|
43 |
-
}
|
44 |
-
});
|
45 |
-
}
|
46 |
-
|
47 |
-
|
48 |
-
// This variable is necessary to handle media inserts into textarea (html mode)
|
49 |
-
var edCanvas;
|
50 |
-
|
51 |
-
// Document ready stuff
|
52 |
-
jQuery(document).ready(function(){
|
53 |
-
// Event handler for widget opening button
|
54 |
-
jQuery('div.widget:has(textarea[id^=widget-black-studio-tinymce]) a.widget-action').live('click', function(){
|
55 |
-
txt_area = jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget'));
|
56 |
-
black_studio_open_deferred_activate_visual_editor(txt_area.attr('id'));
|
57 |
-
return false;
|
58 |
-
});
|
59 |
-
// Event handler for widget saving button
|
60 |
-
jQuery('input[id^=widget-black-studio-tinymce][id$=savewidget]').live('click', function(){
|
61 |
-
txt_area = jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget'));
|
62 |
-
if (typeof(tinyMCE.get(txt_area.attr('id'))) == "object") {
|
63 |
-
black_studio_deactivate_visual_editor(txt_area.attr('id'));
|
64 |
-
}
|
65 |
-
// Event handler for ajax complete
|
66 |
-
jQuery(this).unbind('ajaxSuccess').ajaxSuccess(function(event, xhr, settings) {
|
67 |
-
txt_area = jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget'));
|
68 |
-
black_studio_ajax_deferred_activate_visual_editor(txt_area.attr('id'));
|
69 |
-
});
|
70 |
-
return true;
|
71 |
-
});
|
72 |
-
// Event handler for visual switch button
|
73 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=visual]').live('click', function(){
|
74 |
-
jQuery(this).addClass('active');
|
75 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=html]', jQuery(this).parents('div.widget')).removeClass('active');
|
76 |
-
jQuery('input[id^=widget-black-studio-tinymce][id$=type]', jQuery(this).parents('div.widget')).val('visual');
|
77 |
-
black_studio_activate_visual_editor(jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget')).attr('id'));
|
78 |
-
return false;
|
79 |
-
});
|
80 |
-
// Event handler for html switch button
|
81 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=html]').live('click', function(){
|
82 |
-
jQuery(this).addClass('active');
|
83 |
-
jQuery('a[id^=widget-black-studio-tinymce][id$=visual]', jQuery(this).parents('div.widget')).removeClass('active');
|
84 |
-
jQuery('input[id^=widget-black-studio-tinymce][id$=type]', jQuery(this).parents('div.widget')).val('html');
|
85 |
-
black_studio_deactivate_visual_editor(jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget')).attr('id'));
|
86 |
-
return false;
|
87 |
-
});
|
88 |
-
// Set edCanvas variable when adding from media library (necessary when used in HTML mode)
|
89 |
-
jQuery('.editor_media_buttons a').live('click', function(){
|
90 |
-
edCanvas = jQuery('textarea[id^=widget-black-studio-tinymce]', jQuery(this).parents('div.widget')).get();
|
91 |
-
});
|
92 |
-
});
|
1 |
+
eval(function(p,a,c,k,e,d){e=function(c){return c};if(!''.replace(/^/,String)){while(c--){d[c]=k[c]||c}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('34 22;34 47;34 52;8 53(1){2(\'#\'+1).41("57");15(12(10)=="13"&&12(10.29)=="8"){30(1);15(12(22.24[\'5-6-4-3\'])=="13"){22.24[1]=22.24[\'5-6-4-3\'];22.24[1]["58"]=1;64{4.59(4.62({},22.24[\'5-6-4-3\'],22.24[1]))}60(49){63(49)}}33{10.29("55",42,1)}}}8 30(1){15(12(10)=="13"&&12(10.29)=="8"){15(12(10.18(1))=="13"){45=10.18(1).56();10.29("78",42,1);2(\'16#\'+1).39(45)}}}8 37(1){2(\'7.3:26(#\'+1+\') 25[1^=3-5-6-4][1$=31][46=20]\').50(8(){15(2(\'7.3:26(#\'+1+\') :74\').73()==0&&12(10.18(1))!="13"&&2(\'#\'+1).35(\':36\')){2(\'17[1^=3-5-6-4][1$=20]\',2(9).11(\'7.3\')).23()}33 15(12(10.18(1))!="13"){43(8(){37(1);1=44},51)}})}8 40(1){2(\'7.3:26(#\'+1+\') 25[1^=3-5-6-4][1$=31][46=20]\').50(8(){15(2.28==0&&12(10.18(1))!="13"&&2(\'#\'+1).35(\':36\')){2(\'17[1^=3-5-6-4][1$=20]\',2(9).11(\'7.3\')).23()}33 15(2(\'7.3:26(#\'+1+\') 7.3-75\').35(\':36\')&&12(10.18(1))!="13"){43(8(){40(1);1=44},51)}})}2(76).77(8(){2(\'7.3:26(16[1^=3-5-6-4]) 17.3-72\').27(\'23\',8(14){14.32();21=2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\'));37(21.19(\'1\'));71 67});2(\'7.3[1*=5-6-4] 25[66=68]\').27(\'23\',8(14){14.32();21=2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\'));15(12(10.18(21.19(\'1\')))=="13"){30(21.19(\'1\'))}2(9).65(\'54\').54(8(14,70,69){21=2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\'));40(21.19(\'1\'))})});2(\'17[1^=3-5-6-4][1$=20]\').27(\'23\',8(14){14.32();2(\'25[1^=3-5-6-4][1$=31]\',2(9).11(\'7.3\')).39(\'20\');2(9).41(\'28\');2(\'17[1^=3-5-6-4][1$=38]\',2(9).11(\'7.3\')).48(\'28\');53(2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\')).19(\'1\'))});2(\'17[1^=3-5-6-4][1$=38]\').27(\'23\',8(14){14.32();2(\'25[1^=3-5-6-4][1$=31]\',2(9).11(\'7.3\')).39(\'38\');2(9).41(\'28\');2(\'17[1^=3-5-6-4][1$=20]\',2(9).11(\'7.3\')).48(\'28\');30(2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\')).19(\'1\'))});2(\'.61 17\').27(\'23\',8(){47=2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\')).18();52=2(\'16[1^=3-5-6-4]\',2(9).11(\'7.3\')).19(\'1\')})});',10,79,'|id|jQuery|widget|tinymce|black|studio|div|function|this|tinyMCE|closest|typeof|object|event|if|textarea|a|get|attr|visual|txt_area|tinyMCEPreInit|click|mceInit|input|has|live|active|execCommand|black_studio_deactivate_visual_editor|type|preventDefault|else|var|is|visible|black_studio_open_deferred_activate_visual_editor|html|val|black_studio_ajax_deferred_activate_visual_editor|addClass|false|setTimeout|null|content|value|edCanvas|removeClass|e|each|100|wpActiveEditor|black_studio_activate_visual_editor|ajaxSuccess|mceAddControl|getContent|mceEditor|elements|init|catch|editor_media_buttons|extend|alert|try|unbind|name|true|savewidget|settings|xhr|return|action|size|animated|inside|document|ready|mceRemoveControl'.split('|'),0,{}))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
black-studio-tinymce-widget.php
CHANGED
@@ -3,14 +3,14 @@
|
|
3 |
Plugin Name: Black Studio TinyMCE Widget
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/black-studio-tinymce-widget/
|
5 |
Description: Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
|
6 |
-
Version: 0.
|
7 |
Author: Black Studio
|
8 |
Author URI: http://www.blackstudio.it
|
9 |
License: GPL2
|
10 |
*/
|
11 |
|
12 |
global $black_studio_tinymce_widget_version;
|
13 |
-
$black_studio_tinymce_widget_version = "0.
|
14 |
|
15 |
/* Widget class */
|
16 |
class WP_Widget_Black_Studio_TinyMCE extends WP_Widget {
|
@@ -46,8 +46,13 @@ class WP_Widget_Black_Studio_TinyMCE extends WP_Widget {
|
|
46 |
function form( $instance ) {
|
47 |
$instance = wp_parse_args( (array) $instance, array( 'title' => '', 'text' => '', 'type' => 'visual' ) );
|
48 |
$title = strip_tags($instance['title']);
|
49 |
-
|
50 |
-
|
|
|
|
|
|
|
|
|
|
|
51 |
?>
|
52 |
<input id="<?php echo $this->get_field_id('type'); ?>" name="<?php echo $this->get_field_name('type'); ?>" type="hidden" value="<?php echo esc_attr($type); ?>" />
|
53 |
<p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?></label>
|
@@ -77,13 +82,13 @@ function black_studio_tinymce_init() {
|
|
77 |
register_widget('WP_Widget_Black_Studio_TinyMCE');
|
78 |
}
|
79 |
|
80 |
-
/* Add actions and
|
81 |
if ($pagenow == "widgets.php") {
|
82 |
add_action( 'admin_head', 'black_studio_tinymce_load_tiny_mce');
|
83 |
add_filter( 'tiny_mce_before_init', 'black_studio_tinymce_init_editor', 20);
|
84 |
add_action( 'admin_print_scripts', 'black_studio_tinymce_scripts');
|
85 |
add_action( 'admin_print_styles', 'black_studio_tinymce_styles');
|
86 |
-
add_action( 'admin_print_footer_scripts', '
|
87 |
}
|
88 |
|
89 |
/* Instantiate tinyMCE editor */
|
@@ -93,20 +98,21 @@ function black_studio_tinymce_load_tiny_mce() {
|
|
93 |
remove_filter( 'mce_buttons', 'register_AtD_button' );
|
94 |
remove_filter( 'tiny_mce_before_init', 'AtD_change_mce_settings' );
|
95 |
//remove_all_filters('mce_external_plugins');
|
96 |
-
wp_tiny_mce(false, array());
|
97 |
}
|
98 |
|
99 |
/* TinyMCE setup customization */
|
100 |
function black_studio_tinymce_init_editor($initArray) {
|
101 |
// Remove WP fullscreen mode and set the native tinyMCE fullscreen mode
|
102 |
-
|
103 |
-
|
104 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
105 |
}
|
106 |
-
if (!isset($plugins['fullscreen'])) {
|
107 |
-
$plugins[] = 'fullscreen';
|
108 |
-
}
|
109 |
-
$initArray['plugins'] = implode(',', $plugins);
|
110 |
// Remove the "More" toolbar button
|
111 |
$initArray['theme_advanced_buttons1'] = str_replace(',wp_more', '', $initArray['theme_advanced_buttons1']);
|
112 |
// Do not remove linebreaks
|
@@ -131,19 +137,53 @@ function black_studio_tinymce_init_editor($initArray) {
|
|
131 |
function black_studio_tinymce_scripts() {
|
132 |
global $black_studio_tinymce_widget_version;
|
133 |
add_thickbox();
|
134 |
-
|
135 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
136 |
}
|
137 |
|
138 |
/* Widget css loading */
|
139 |
function black_studio_tinymce_styles() {
|
140 |
-
|
141 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
142 |
}
|
143 |
|
144 |
-
|
145 |
-
|
146 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
147 |
}
|
148 |
|
149 |
?>
|
3 |
Plugin Name: Black Studio TinyMCE Widget
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/black-studio-tinymce-widget/
|
5 |
Description: Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
|
6 |
+
Version: 0.7
|
7 |
Author: Black Studio
|
8 |
Author URI: http://www.blackstudio.it
|
9 |
License: GPL2
|
10 |
*/
|
11 |
|
12 |
global $black_studio_tinymce_widget_version;
|
13 |
+
$black_studio_tinymce_widget_version = "0.7"; // This is used internally - should be the same reported on the plugin header
|
14 |
|
15 |
/* Widget class */
|
16 |
class WP_Widget_Black_Studio_TinyMCE extends WP_Widget {
|
46 |
function form( $instance ) {
|
47 |
$instance = wp_parse_args( (array) $instance, array( 'title' => '', 'text' => '', 'type' => 'visual' ) );
|
48 |
$title = strip_tags($instance['title']);
|
49 |
+
if (function_exists('esc_textarea')) {
|
50 |
+
$text = esc_textarea($instance['text']);
|
51 |
+
}
|
52 |
+
else {
|
53 |
+
$text = stripslashes( wp_filter_post_kses( addslashes( $instance['text'] ) ) );
|
54 |
+
}
|
55 |
+
$type = esc_attr($instance['type']);
|
56 |
?>
|
57 |
<input id="<?php echo $this->get_field_id('type'); ?>" name="<?php echo $this->get_field_name('type'); ?>" type="hidden" value="<?php echo esc_attr($type); ?>" />
|
58 |
<p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?></label>
|
82 |
register_widget('WP_Widget_Black_Studio_TinyMCE');
|
83 |
}
|
84 |
|
85 |
+
/* Add actions and filters (only in widgets admin page) */
|
86 |
if ($pagenow == "widgets.php") {
|
87 |
add_action( 'admin_head', 'black_studio_tinymce_load_tiny_mce');
|
88 |
add_filter( 'tiny_mce_before_init', 'black_studio_tinymce_init_editor', 20);
|
89 |
add_action( 'admin_print_scripts', 'black_studio_tinymce_scripts');
|
90 |
add_action( 'admin_print_styles', 'black_studio_tinymce_styles');
|
91 |
+
add_action( 'admin_print_footer_scripts', 'black_studio_tinymce_footer_scripts');
|
92 |
}
|
93 |
|
94 |
/* Instantiate tinyMCE editor */
|
98 |
remove_filter( 'mce_buttons', 'register_AtD_button' );
|
99 |
remove_filter( 'tiny_mce_before_init', 'AtD_change_mce_settings' );
|
100 |
//remove_all_filters('mce_external_plugins');
|
|
|
101 |
}
|
102 |
|
103 |
/* TinyMCE setup customization */
|
104 |
function black_studio_tinymce_init_editor($initArray) {
|
105 |
// Remove WP fullscreen mode and set the native tinyMCE fullscreen mode
|
106 |
+
if (get_bloginfo('version') < "3.3") {
|
107 |
+
$plugins = explode(',', $initArray['plugins']);
|
108 |
+
if (isset($plugins['wpfullscreen'])) {
|
109 |
+
unset($plugins['wpfullscreen']);
|
110 |
+
}
|
111 |
+
if (!isset($plugins['fullscreen'])) {
|
112 |
+
$plugins[] = 'fullscreen';
|
113 |
+
}
|
114 |
+
$initArray['plugins'] = implode(',', $plugins);
|
115 |
}
|
|
|
|
|
|
|
|
|
116 |
// Remove the "More" toolbar button
|
117 |
$initArray['theme_advanced_buttons1'] = str_replace(',wp_more', '', $initArray['theme_advanced_buttons1']);
|
118 |
// Do not remove linebreaks
|
137 |
function black_studio_tinymce_scripts() {
|
138 |
global $black_studio_tinymce_widget_version;
|
139 |
add_thickbox();
|
140 |
+
if (get_bloginfo('version') >= "3.3") {
|
141 |
+
wp_enqueue_script('wplink');
|
142 |
+
wp_enqueue_script('wpdialogs-popup');
|
143 |
+
}
|
144 |
+
else {
|
145 |
+
wp_enqueue_script('media-upload');
|
146 |
+
}
|
147 |
+
wp_enqueue_script('black-studio-tinymce-widget', plugins_url('black-studio-tinymce-widget.js', __FILE__), array('jquery'), $black_studio_tinymce_widget_version);
|
148 |
}
|
149 |
|
150 |
/* Widget css loading */
|
151 |
function black_studio_tinymce_styles() {
|
152 |
+
global $black_studio_tinymce_widget_version;
|
153 |
+
if (get_bloginfo('version') < "3.3") {
|
154 |
+
wp_enqueue_style('thickbox');
|
155 |
+
}
|
156 |
+
else {
|
157 |
+
wp_enqueue_style('wp-jquery-ui-dialog');
|
158 |
+
}
|
159 |
+
wp_enqueue_style('black-studio-tinymce-widget', plugins_url('black-studio-tinymce-widget.css', __FILE__), array(), $black_studio_tinymce_widget_version);
|
160 |
}
|
161 |
|
162 |
+
|
163 |
+
/* Footer script */
|
164 |
+
function black_studio_tinymce_footer_scripts() {
|
165 |
+
// Setup for WP 3.1 and previous versions
|
166 |
+
if (get_bloginfo('version') < "3.2") {
|
167 |
+
if (function_exists('wp_tiny_mce')) {
|
168 |
+
wp_tiny_mce(false, array());
|
169 |
+
}
|
170 |
+
if(function_exists('wp_tiny_mce_preload_dialogs')) {
|
171 |
+
wp_tiny_mce_preload_dialogs();
|
172 |
+
}
|
173 |
+
}
|
174 |
+
// Setup for WP 3.2.x
|
175 |
+
else if (get_bloginfo('version') < "3.3") {
|
176 |
+
if (function_exists('wp_tiny_mce')) {
|
177 |
+
wp_tiny_mce(false, array());
|
178 |
+
}
|
179 |
+
if(function_exists('wp_preload_dialogs')) {
|
180 |
+
wp_preload_dialogs( array( 'plugins' => 'wpdialogs,wplink,wpfullscreen' ) );
|
181 |
+
}
|
182 |
+
}
|
183 |
+
// Setup for WP 3.3 - New Editor API
|
184 |
+
else {
|
185 |
+
wp_editor('', 'black-studio-tinymce-widget');
|
186 |
+
}
|
187 |
}
|
188 |
|
189 |
?>
|
readme.txt
CHANGED
@@ -1,22 +1,24 @@
|
|
1 |
=== Black Studio TinyMCE Widget ===
|
2 |
Contributors: marcochiesi, thedarkmist
|
3 |
Donate link: http://www.blackstudio.it/pagamento/
|
4 |
-
Tags: wysiwyg, widget, tinymce, editor, rich text, rich text editor, visual editor, wysiwyg editor, tinymce editor, widget editor, html editor, wysiwyg widget, html widget, editor widget, text widget, rich text widget, enhanced text widget, tinymce widget, visual widget,
|
5 |
-
Requires at least: 3.
|
6 |
-
Tested up to: 3.
|
7 |
-
Stable tag: 0.
|
8 |
|
9 |
Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
|
10 |
|
11 |
== Description ==
|
12 |
-
This plugin adds a WYSIWYG text widget based on the standard TinyMCE WordPress editor. This is intended to overcome the limitations of the default WordPress text widget, so that you can visually add rich text contents to your sidebars.
|
13 |
|
14 |
= Features =
|
15 |
|
16 |
* Add rich text widgets to your sidebar using visual editor
|
17 |
-
*
|
18 |
-
*
|
|
|
19 |
* Fullscreen editing mode supported
|
|
|
20 |
|
21 |
== Installation ==
|
22 |
|
@@ -26,7 +28,7 @@ This section describes how to install the plugin and get it working.
|
|
26 |
2. Activate the plugin through the 'Plugins' menu in WordPress
|
27 |
3. Go to Widgets Screen
|
28 |
4. Drag Widget to desired sidebar
|
29 |
-
5. Fill in the widget title and text
|
30 |
|
31 |
== Screenshots ==
|
32 |
|
@@ -34,24 +36,29 @@ This section describes how to install the plugin and get it working.
|
|
34 |
|
35 |
== Changelog ==
|
36 |
|
|
|
|
|
|
|
|
|
|
|
37 |
= 0.6.5 =
|
38 |
* Forced TinyMCE editor to not automatically add/remove paragraph tags when switching to HTML mode (you may need to re-edit your widgets to adjust linebreaks, if you were using multiple paragraphs)
|
39 |
|
40 |
= 0.6.4 =
|
41 |
* Fixed compatibility issue with "Jetpack / After the Deadline" plugin
|
42 |
-
* Optimization of
|
43 |
|
44 |
= 0.6.3 =
|
45 |
-
* Fixed
|
46 |
|
47 |
= 0.6.2 =
|
48 |
-
* Fixed
|
49 |
|
50 |
= 0.6.1 =
|
51 |
-
* Fixed
|
52 |
|
53 |
= 0.6 =
|
54 |
* Added support for Wordpress Media Library
|
55 |
|
56 |
= 0.5 =
|
57 |
-
* First Beta
|
1 |
=== Black Studio TinyMCE Widget ===
|
2 |
Contributors: marcochiesi, thedarkmist
|
3 |
Donate link: http://www.blackstudio.it/pagamento/
|
4 |
+
Tags: wysiwyg, widget, tinymce, editor, image, media, rich text, rich text editor, visual editor, wysiwyg editor, tinymce editor, widget editor, html editor, wysiwyg widget, html widget, editor widget, text widget, rich text widget, enhanced text widget, tinymce widget, visual widget, image widget, media widget
|
5 |
+
Requires at least: 3.0
|
6 |
+
Tested up to: 3.3-beta4
|
7 |
+
Stable tag: 0.7
|
8 |
|
9 |
Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
|
10 |
|
11 |
== Description ==
|
12 |
+
This plugin adds a WYSIWYG text widget based on the standard TinyMCE WordPress visual editor. This is intended to overcome the limitations of the default WordPress text widget, so that you can visually add rich text contents to your sidebars, with no knowledge of HTML required.
|
13 |
|
14 |
= Features =
|
15 |
|
16 |
* Add rich text widgets to your sidebar using visual editor
|
17 |
+
* Switch between Visual mode and HTML mode
|
18 |
+
* Insert images/videos from Wordpress Media Library
|
19 |
+
* Insert links to existing Wordpress pages/posts
|
20 |
* Fullscreen editing mode supported
|
21 |
+
* No annoying ads/nag-screens
|
22 |
|
23 |
== Installation ==
|
24 |
|
28 |
2. Activate the plugin through the 'Plugins' menu in WordPress
|
29 |
3. Go to Widgets Screen
|
30 |
4. Drag Widget to desired sidebar
|
31 |
+
5. Fill in the widget title and (rich) text
|
32 |
|
33 |
== Screenshots ==
|
34 |
|
36 |
|
37 |
== Changelog ==
|
38 |
|
39 |
+
= 0.7 =
|
40 |
+
* Added compatibility for upcoming Wordpress 3.3 (currently beta 4)
|
41 |
+
* Added compatibility for previous Wordpress 3.0 and 3.1
|
42 |
+
* Optimization/compression of javascript code
|
43 |
+
|
44 |
= 0.6.5 =
|
45 |
* Forced TinyMCE editor to not automatically add/remove paragraph tags when switching to HTML mode (you may need to re-edit your widgets to adjust linebreaks, if you were using multiple paragraphs)
|
46 |
|
47 |
= 0.6.4 =
|
48 |
* Fixed compatibility issue with "Jetpack / After the Deadline" plugin
|
49 |
+
* Optimization of javascript/css loading
|
50 |
|
51 |
= 0.6.3 =
|
52 |
+
* Fixed javascript issue preventing the plugin from working correctly with some browsers
|
53 |
|
54 |
= 0.6.2 =
|
55 |
+
* Fixed javascript issue with Wordpress Media Library inserts in HTML mode
|
56 |
|
57 |
= 0.6.1 =
|
58 |
+
* Fixed javascript issue preventing editor to show up in some cases
|
59 |
|
60 |
= 0.6 =
|
61 |
* Added support for Wordpress Media Library
|
62 |
|
63 |
= 0.5 =
|
64 |
+
* First Beta release
|