Implemented Allow custom BBCode

Paul B

XenForo moderator
Staff member
I know this has been discussed on various threads but as far as I am aware, the request hasn't been made directly to allow custom BBCode.

I have about 50 or so custom BBCodes in use on my site which are added easily via the ACP.
I would like to see the same functionality in XF as these codes are crucial to the functionality of my site.

Additionally, if there is a simple way of adding custom BB Code buttons to the TinyMCE editor then that would be extremely useful.
 
Upvote 69
This suggestion has been implemented. Votes are no longer accepted.
Wut about giving a list of those 50 custom ones, I have no idea what they all are...

By the way. If we're gonna implent 50+ codes, the quick reply header will be stuffed with icons.
I think that only the most used ones should be added than.
 
Wut about giving a list of those 50 custom ones, I have no idea what they all are...
They're custom to my site - I created them.

By the way. If we're gonna implent 50+ codes, the quick reply header will be stuffed with icons.
I think that only the most used ones should be added than.
The decision would be with the site owner to decide which ones to add.
 
TinyMCE is suppose to be completely customizable.

And I doubt Mike and Kier would leave out custom BBCodes (Nearly every solution has them, and they tend to be used often).
 
They're not in now, though they're not that hard.

I'm not sure I'd agree with them being used "often" though.
 
I'm not sure I'd agree with them being used "often" though.
I daren't show you some of the posts on my forum then :D

To be fair though most of our custom BBCode is for tables as we use them a lot to display standings & results, etc.
 
They're not in now, though they're not that hard.

I'm not sure I'd agree with them being used "often" though.

Most sites I've seen use BBCode addons, or create their own.

I don't mind if its there or not, because I try not to add to many icons to my editor.
 
The attached screenshot shows how BBCode is handled in the ACP in phpBB.

Of course any additions to the editor have to be done via template edits.
 

Attachments

  • bbcode.webp
    bbcode.webp
    45.7 KB · Views: 183
A way to mange custom BBCodes would be extremely useful.

You have a 'dmv' BBCode, what does that stand for?
 
DMV is for DailyMotion video :)

This is one of my favourite BBCodes:

Code:
<div class="spoiler"><div class="quotetitle"><input type="button" value="{TEXT1}" style="font-size:11px;margin:0px;padding:0px;" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';        this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = '{TEXT1}'; }" /></div><div class="quotecontent"><div style="display: none;">{TEXT2}</div></div></div>

[button={TEXT1}]{TEXT2}[/button]

It's used for e.g. quizzes: http://www.cliptheapex.com/forum/viewtopic.php?f=52&t=1905
 
DMV is for DailyMotion video :)

This is one of my favourite BBCodes:

Code:
<div class="spoiler"><div class="quotetitle"><input type="button" value="{TEXT1}" style="font-size:11px;margin:0px;padding:0px;" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';        this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = '{TEXT1}'; }" /></div><div class="quotecontent"><div style="display: none;">{TEXT2}</div></div></div>

[button={TEXT1}]{TEXT2}[/button]

It's used for e.g. quizzes: http://www.cliptheapex.com/forum/viewtopic.php?f=52&t=1905

Wow... I really like that implementation... I'm used to VB where you are limited to one {param} and one {option}.

Anyway custom bb codes are an ABSOLUTE necessity... I don't particularly care if they have editor buttons or not but it would be nice if after so many buttons they made a new line in the editor rather then making the editor window wider like in vB.

I'm actually quite fond of my BBCode collection... always looking for more.
http://www.juot.net/forums/showthread.php?t=20432
 
Top Bottom