Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

TinyMCE produce P elements on enter/return instead of BR elements?

br elements enter p Return tinymce
0
Posted

TinyMCE produce P elements on enter/return instead of BR elements?

0

Here are a few reasons why BR elements and the force_br_newlines aren’t enabled by default and why forced_root_block is. • Paragraphs were invented for a reason. Try modifying paragraph margins using CSS without using paragraph tags and you see what we mean. • The IE WYSIWYG environment is built on handling paragraphs when it comes to alignment/list management and much more. TinyMCE and other editors will start producing lots of strange results if you enable force_br_newlines. • The space between the paragraphs can be removed using a simple CSS trick like this. p {margin:0; padding: 0;}. This is not possible with BR elements, since the whole line is not wrapped in a container. So P elements gives you the flexibility to choose. • If you really must have BR instead of paragraph elements for some reason – for example to interface with Flash or send e-mail messages –, then simply post process them away by replacing

with
, which takes care of P tags with

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123