Welcome! To use this support forum, please Login or Join Today!

   

Losing paragraphs switching between Visual and Text mode

{name}
RankRankRank

Total Posts: 52

Joined 2014-11-03

PM

 
Hi Casey,

What would you suggest for addressing this problem of losing paragraph and break tags switching between Visual and Text mode? Here's a thread about it:
https://wordpress.org/support/topic/paragraph-tags-disappear-between-html-and-visual

I'm trying to add paragraphs in this page and it's driving me crazy:
http://votec.eplatt.com/products/

The way to workaround for now it seems to be by adding
<div><p>content</p> <p>content</p>  </div
, wrapping the whole section in a div. You then see line breaks in Visual mode instead of your paragraphs, and the
<p
tags stripped out, but at least it preserves formatting.



Tanks
{name}
RankRankRankRank

Total Posts: 3667

Joined 2011-04-27

PM

 
WordPress will do that. It's probably the most popular complaint on the WP forums. I usually circumvent it by giving P tags a class name.

<class="p">...paragraph text...</p
{name}
RankRankRank

Total Posts: 52

Joined 2014-11-03

PM

 
I'm trying this out. Seems to help. So empty DIV tags are no longer necessary?


Thanks.
{name}
RankRankRankRank

Total Posts: 3667

Joined 2011-04-27

PM

 
Unless the empty div tag has a rule applied to it, no.

You can also try creating a custom field to your Page or Post named “wpautop” with a value of “false”. This will disable the WordPress wpautop() function for that post entirely. The downside is that you have to manually add all P tags.