I would like the default
<p> elements that are added to the (TinyMCE) editor when users post content, to have a
dir attribute as well.
Reasoning: When the editor is displayed to users, it is wrapped in an html element with a dir attribute (determined by locale). Thus, the text direction to the user (while he is writing the content) reflects his locale.
p elements that are part of the user's content (which I will be storing in the database) do not have the
dir attribute attached.
I would like to attach it so that when the content is later retrieved from the database, it is shown the same way that it looked to the user/author when he wrote it.
How can I add the
dir attribute to the
p tags by default?
Another Approach: I have directionality buttons as part of my editor, if I can select these buttons by default, this will take care of the problem as well.