Quicktags on all textarea.. Not working on plugin?

it you’re not seeing the buttons, try to call QTags._buttonsInit(); right after you call the quicktags( settings ); function. quicktags(settings); QTags._buttonsInit(); Following also works for me qt_editor = new QTags( { ‘id’: ‘my_editor’, ‘buttons’: ‘strong,em,link’ } ); QTags._buttonsInit(); Also, it seems that adding a button via QTags.addButton() function also makes your toolbar to display qt_editor … Read more

How to Make admin Sidebar Menu always be Collapse by code

To make the admin sidebar menu always be collapsed, try adding the following code in the functions.php file of your child theme, or add it in your site using a plugin like Code Snippets, or Add Actions and Filters. global $user_ID; $user_fold = get_user_meta( $user_ID, ‘wp_user-settings’, true ); $exp_array = explode( “&”, $user_fold ); $search_array … Read more

Adding TinyMCE custom buttons when using teeny_mce_before_init

I believe that you have already registered your shortcode. Now what we need to do is to initiate the Button. Once the shortcode is registered [ph_min] let’s check if user can use rich editing: function add_highlight_button() { if ( ! current_user_can(‘edit_posts’) && ! current_user_can(‘edit_pages’) ) return; if ( get_user_option(‘rich_editing’) == ‘true’) { add_filter(‘mce_external_plugins’, ‘add_tcustom_tinymce_plugin’); add_filter(‘mce_buttons’, … Read more

Custom Shortcode and Button not Working after 3.9 update

Try like this: <script type=”text/javascript”> tinymce.init({ selector: “textarea”, toolbar: “mybutton”, setup: function(editor) { editor.addButton(‘mybutton’, { type: ‘splitbutton’, text: ‘My button’, icon: false, onclick: function() { editor.insertContent(‘Main button’); }, menu: [ {text: ‘Menu item 1’, onclick: function() { tinyMCE.activeEditor.execCommand(“myPopup”, false, { title: ‘Divider’, identifier: ‘divider’ })}}, {text: ‘Menu item 2’, onclick: function() {editor.insertContent(‘Menu item 2’);}} ] … Read more

Custom “Publish” / “Update” button &

You can stimulate click to Update post button like this.. Adding submit or update button to custom metabox? <script> jQuery(‘.metabox_submit’).click(function(e) { e.preventDefault(); jQuery(‘#publish’).click(); }); </script> <input type=”submit” class=”metabox_submit” value=”Submit” />

File not found.