There is a problem with custom styles in RTE. Everysthing is ok, when you try to apply simple style to selected text, but if style is more complex, it applies to entire block (paragraph).
For example, I have a simple custome style for RTE:
and I want to apply it to an <a> element, and that what I got:
But why? Why selected text just does't wraps into custom element?
<p><a class="button-default">This is a button Cras consequat aliquet consectetur. </a></p>
And another strange behavior - if I apply custom class like a.button-default to a link, it does't work, but if not, it transforms entire text block int a.button-default
But style like simple .button-default (without tag) applying this way on:
<p><a href="/123"><span class="button-default">Button</span></a> Some text</p>
RTE (TinyMCE) styles applies to entire block
Hello, Umbracians
There is a problem with custom styles in RTE. Everysthing is ok, when you try to apply simple style to selected text, but if style is more complex, it applies to entire block (paragraph).
For example, I have a simple custome style for RTE:
and I want to apply it to an
<a>
element, and that what I got:But why? Why selected text just does't wraps into custom element?
Hi Dmitriy
What does the outputted HTML look like? Can you perhaps please post a snippet?
The RTE can be a bit tricky with custom style options sometimes but what you're trying to do should be possible.
/Jan
Here:
And another strange behavior - if I apply custom class like
a.button-default
to a link, it does't work, but if not, it transforms entire text block inta.button-default
But style like simple
.button-default
(without tag) applying this way on:is working on a reply...