we_are_borg
Well-known member
If you make a simple BB Code like so:
You can make a text in a in another background color that you define with the {option}.
But you can also use the following code:
Now you get the background color with the text but it now has a border because of the extra ;border-style: solid; but this was not included in the replacement html. This is unwanted you do not want people to make up their own css in the BB Code if the second option is not being called it should be ignored.
As example you can replace the border for background image.
This is unwanted behaviour.
Code:
<span style="background-color: {option}; padding: 0 2px">{text}</span>
Usage: [bg=red]This is some text with a red background[/bg]
You can make a text in a in another background color that you define with the {option}.
But you can also use the following code:
Code:
[bg=red;border-style: solid;]This is some text with a red background and a solid border.[/bg]
Now you get the background color with the text but it now has a border because of the extra ;border-style: solid; but this was not included in the replacement html. This is unwanted you do not want people to make up their own css in the BB Code if the second option is not being called it should be ignored.
As example you can replace the border for background image.
Code:
[bg=red;background-image: url("paper.gif");]This is some text with a red background and a solid border.[/bg]
This is unwanted behaviour.