Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

When I create a new page and put <br class="clear"> into the HTML view it gets rendered as

<p>
  <br class="clear">
</p>

This causes problems with the theme http://www.gallyapp.com/tf_themes/?theme=Lotus where the <br> is not wrapped.

How can remove the wrapping?

share|improve this question
1  
There's already a few solutions to this problem in this thread. –  Jono Warren Oct 5 '11 at 9:13
1  
Does using <div class="clear"></div> solve the problem? I think using a div will work around the issue. –  t31os Oct 6 '11 at 13:07
add comment

2 Answers

up vote 0 down vote accepted

Use shortcode instead of <br class="clear">

share|improve this answer
    
Thanks, is there a particular shortcode you had in mind? Or do you mean I should create my own shortcode with <br class="clear"> as content? –  Cilvic Oct 5 '11 at 13:10
    
@Civic, I mean create your own. Another solution is to filter the content It's even more easier. –  Alexey Oct 5 '11 at 13:34
add comment

you can strip all the filters by calling get_the_content() instead of the_content()

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.