Joomla - Custom Text Button Plugin


This simple Joomla plugin adds an additional button to the editor page. In plugin parameters you can set any text which will be added to your articles then button is pressed. Can be used with add frequently used phrases or code into your articles (such as custom module positions from Content - Load Modules plugin).


1. Install the plugin

2. Open Extensions > Plug-in Manager > Button - Custom Text

  • Change status to Enabled
  • Enter your Custom Text
  • Enter Button Label (Optional)

Custom Text Button Plugin Parameters

3. Save changes and open new or existing article

4. Place cursor where you want for your text to appear and press Cust Text Button

Custom Text Button Plugin in Article


Download version 1.4

Compatible and tested with Joomla 2.5 and 3.1

Please report all bugs and errors here.

If you need to add a second button, download this

Comments (Legacy)  

# Olg 2015-03-29 11:52
Button don't work in Joomla! 3.4.1. (JCE editor). Button appear in editor, but when push the button text don't appear and article close.
# Valy 2014-11-03 14:16
I have instaled the plugin , and made a modification. I have changed type to textarea and added cols and row as 30 and 4.
I have added the code for a table. Now when i press the button it`s not inserting anything and it sends me to the control panel. Any ideea ?

Thank you.
# Qian 2014-09-09 10:23
thanks!I will try it
# tanadol 2014-05-18 12:12
# Roli 2014-05-07 14:58
Button not appearing!
Joomla 3.3 Custom Text Button v1.4 activated.
Any successions?
# admin 2014-05-09 16:32
Just tested on fresh 3.3 installation - works fine. Do you have other plugins/compone nts that add similar buttons?
# Roli 2014-05-10 12:09
Thanks for reply. Can't see any failure.
Using the button at bottom of Editor-Window, get the string {loadposition Gallery}. But no Button appears, when the article is displayed.
# asifagaria 2014-04-13 01:24
This button nothing work joomla zoo or k2
Automobilių nuoma Ka
# Automobilių nuoma Ka 2013-08-23 14:38
Thanks good button
+1 # dave 2013-08-18 08:38
Found the download. Enabled plugin and added text. Button wouldn't show and got this error message:

Use of undefined constant PLG_SYSTEM_J2XM L_BUTTON_EXPORT - assumed 'PLG_SYSTEM_J2XM L_BUTTON_EXPORT' in C:\xampp\htdocs \sub\plugins\sy stem\j2xml\j2xm l.php on line 95

Any ideas what the problem might be, please?
# admin 2013-08-19 08:58
That error seems to be coming from J2XML plugin.
# Jesse 2013-08-14 03:30
I'm trying to use your plugin with Ari Document Viewer.

I want your plugin to add the text:

{aridoc engine="google" width="500" height="400"}media/k2/attachments/YOUR-FILENAME-HERE{/aridoc}

It works, except Ari Doc processes it when you click the button so the text doesn't appear, just the box where Ari Doc is trying to display a file that hasn't been specified. I did contact them first...they looked into it and said their plugin isn't compatible with yours. So, I'm assuming you won't be able to help, but I wanted to confirm there isn't anything I could do to have it insert the text without Ari Doc processing it before it's published.

# diego 2013-07-17 17:14
Jose Noble
-2 # Jose Noble 2013-06-15 00:41
I have downloaded the plugin but it does not work in joomla 1.5, tells xml installation error
# admin 2013-06-17 09:09
It's only been tested with Joomla 2.5 and 3.1
# tarek 2013-05-22 12:58
thanks a lot for this excellent little simple plugin :)
# ARTS 2013-05-11 10:10
problems with
+1 # Wayne 2013-04-30 16:50
Just installed under joomla 3.1 and the button it creates is invisible - mouseover shows tooltip, and if you click that area it works, but no button shows on the button bar... any ideas?
# admin 2013-05-22 07:08
Upgrade to the latest version. Starting v1.3 plugin is Joomla 3.1 compatible.
Jerry Titus
# Jerry Titus 2013-04-28 12:37
I'm trying to add the following code to the button but can't seem to get it to display...

Popup link in a 800x600 modal window. Replace *all* of this text with the text to be displayed
Jerry Titus
# Jerry Titus 2013-04-28 13:00
The code I am trying to enter is the third example on this page, below the picture of the joomla modal.
# admin 2013-04-29 10:13
Try placing \ (backslash) in front of ' (single quotes)
# Juhy 2013-04-04 07:36
When i click on costum button, the custom text is inserted, but then page go refresh - why? i'm using Google Chrome browser
# Marco 2013-04-04 01:44
Any possibility that you can add this feature?
When a user clicks on the custom button, it prompts them to fill in an input field?

Sort of like how the default "page break" button asks for a "Page Title" and "Table of contents alias"
# Gorgo 2013-04-03 11:17
It's is not possible when I click on button, he add a specific image in the text editor ? (but without pass by toggle editor) I would like he put directly image.

Thanks a lot !
# maz2390 2013-01-23 02:00
I'm trying to add this code to the button so my bloggers have easier access to a lightbox feature however, it isn't saving it. Maybe because it's too long? It saves it if I delete some of it!
# admin 2013-01-23 08:15
What code? Maybe Joomla is stripping it out.
Try setting Text Filters to No Filtering
# maz2390 2013-01-23 13:18
Quoting admin:
What code? Maybe Joomla is stripping it out.
Try setting Text Filters to No Filtering

this code:

a data-lightbox=" transitionIn:fa de; transitionOut:f ade;" href="/joomla/v antage/images/d emo/gallery/col umn_5/1_big.jpg ">
# maz2390 2013-01-23 13:20
a data-lightbox=" transitionIn:fa de; transitionOut:f ade;" href="/joomla/v antage/images/d emo/gallery/col umn_5/1_big.jpg " img class="pic3d" src="/joomla/va ntage/images/de mo/gallery/colu mn_5/1.jpg" border="0" alt="fade" width="162" height="104"

had to edit out tags
# admin 2013-01-23 13:53
Can you add long text if doesn't have any html tags? Just trying to find out if tags are causing your issue.
# maz2390 2013-01-23 14:05
Yeah that seems fine
+1 # admin 2013-03-06 14:00
Issue is now resolved. Download version 1.2
# zefrenchmen 2012-12-22 19:39
Pardon the n00b question, but I want to use the buttons to insert a link that comes back often on my site. The button won't hold the html, it strips it to the text itself. Ideas of what I'm doing wrong ?
# admin 2013-03-06 14:02
This is fixed in version 1.2
# lakshmanan 2012-10-30 13:10
Simple & powerful plugin... class plgButtonMyButt on extends JPlugin { function onDisplay($name ) { $txt = $this->params-> get('my_button' , '[set your custom text in plugin parameters]'); $label = $this->params-> get('label', 'My Button'); $jsCode = " function insertMyButton( editor) { jInsertEditorTe xt('".$txt."', editor); } "; $doc = JFactory::getDo cument(); $doc->addScript Declaration($js Code); $button = new JObject(); $button->set('t ext',$label); $button->set('n ame','blank'); $button->set('o nclick', 'insertMyButton (\''.$name.'\') '); return $button; } }

I've duplicated the class and added few buttons.

Must have plugin...!!!
+1 # roman 2012-12-09 02:04
how to create multiply buttons?
Lakshmanan PHP
# Lakshmanan PHP 2012-12-09 17:30
By duplicating the plugin you can create more buttons.

copy and paste custom text plugin. rename it to your button name. lets call it my button.

replace the custom text class name with my button in all occurrences.

Please refer the sample code in my previous comment.

Hope this helps
# Paolo 2014-11-28 13:30
Please could you explain step by step better for a newbie?
# Vityushka 2012-10-03 10:30
Is it possible to add formatted text?
# admin 2013-03-06 14:01
Yes, in version 1.2 you can add HTML code.
+3 # Mike 2012-09-15 13:44
It would be cool if we could set a title for the button in the parameter !

btw good job, thanks.
+1 # admin 2012-09-21 15:21
This is now implemented. Download version 1.1
+13 # Chris 2012-09-13 11:30
Is it possible to add multiple buttons - i.e. 1st button with some text, 2nd button with different text, etc.?
+1 # admin 2012-09-13 13:36
Not currently. May add this to later versions though.


Subscribe to receive occasional updates on new posts.
Your email will not be used for any other purpose and you can unsubscribe at any time.
Please wait
Privacy Policy