523 posts WeNotMe
  • Has been part of the Envato Community for over 5 years
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has referred 1+ members
  • Elite Author: Sold more than $75,000 on Envato Market
+2 more
codeex
says

Hi, thank you for the tutorial. It seems like text editor is not working. When I change to ‘Text’ tab, content is still formated like in Visual editor.

try this

(function($) {
"use strict";   

   tinymce.PluginManager.add( 'ubl_location', function( editor, url ) {

      editor.addButton( 'shortcodes', {
         type: 'listbox',
         icon: false,
         title:  'Shortcodes',
         onclick : function(e) {},
         values: [
            {text: 'Alerts',onclick:function(){
               //code here
            }},
         ]
      });

   });

})(jQuery);
2 posts
  • Has been part of the Envato Community for over 1 year
matrasoriginal
says


Hi, thank you for the tutorial. It seems like text editor is not working. When I change to ‘Text’ tab, content is still formated like in Visual editor.

try this

(function($) {
"use strict";   

   tinymce.PluginManager.add( 'ubl_location', function( editor, url ) {

      editor.addButton( 'shortcodes', {
         type: 'listbox',
         icon: false,
         title:  'Shortcodes',
         onclick : function(e) {},
         values: [
            {text: 'Alerts',onclick:function(){
               //code here
            }},
         ]
      });

   });

})(jQuery);

It works! Thank you!

523 posts WeNotMe
  • Has been part of the Envato Community for over 5 years
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has referred 1+ members
  • Elite Author: Sold more than $75,000 on Envato Market
+2 more
codeex
says



Hi, thank you for the tutorial. It seems like text editor is not working. When I change to ‘Text’ tab, content is still formated like in Visual editor.

try this

(function($) {
"use strict";   

   tinymce.PluginManager.add( 'ubl_location', function( editor, url ) {

      editor.addButton( 'shortcodes', {
         type: 'listbox',
         icon: false,
         title:  'Shortcodes',
         onclick : function(e) {},
         values: [
            {text: 'Alerts',onclick:function(){
               //code here
            }},
         ]
      });

   });

})(jQuery);
It works! Thank you!

Your Welcome! :)

by
by
by
by
by
by