Roberts code sample works and this is what it should look like in the ACP:
BBCode usage:
Code: Select all
[hr][/hr]
Code: Select all
<hr style="height:5px;border:none;color:#000;background-color:#000;" />
Code: Select all
Creates a horizontal line.
Code: Select all
[hr][/hr]
Code: Select all
<hr style="height:5px;border:none;color:#000;background-color:#000;" />
Code: Select all
Creates a horizontal line.
Adding variables would be quite complicated for the users as they would have to add several pieces of information but I don't think it's impossible. If you want it customisable you may be better off requesting an extension, if there isn't one already, or you could create several BBCodes with the parameters you want but it seems a bit of an overkill.DWFII wrote:I was hoping for something variable in terms of height (thickness ) and perhaps even colour
I meant user changeable. But I understand the html replacement and how it works and probably it will be more than sufficient.Lumpy Burgertushie wrote:do you mean something you can change each time you use the bbcode or do you just want one hr bbcode but different thickness and color than what I posted?
if it is the latter, then you simply change the pixels to what you want and the color to what you want.
robert
this will work I'm almost certain--it's in the clipboard right now so soon as I get done asking one more question I'm headed for th eACP.Lumpy Burgertushie wrote:show us the exact html replacement you are using for your custom hr bbcode.
then we can give you exact css to add to that code.
for instance, is you want a hr to be 5pixels wide/thick and black your html replacement would be like this:
robertCode: Select all
<hr style="height:5px;border:none;color:#000;background-color:#000;" />
[redhr][/redhr]
<hr style="height:5px;border:none;color:#F9072B;background-color:#F9072B;" />
That's interesting.Lumpy Burgertushie wrote:nice work. I was wondering what you were doing with this.
you could setup several different bbcodes for different colors. just name then with the color:
[redhr][/redhr]
html:
<hr style="height:5px;border:none;color:#F9072B;background-color:#F9072B;" />
etc. etc.
robert
[hrcode][/hrcode]
[hr]
tag? Not [hr][/hr]
. HR
is not a pair tag...sorry, what does that mean? if you want to create a hr bbcode you must have both the open and close tags for it. the html replacement does not need a closing tag but the bbcode does.R3gi wrote:Hello,
please is there some way to have only[hr]
tag? Not[hr][/hr]
.HR
is not a pair tag...