This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Any idea what could cause new <br> tags to get added to the rendered code?

 
Dan Acuff
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The following happens. I am defaulted to the Credit Card radio button. I decide I want to click the PayPal radio button. I again decide to click the Credit Card radio button. At that very moment 2 extra break tags are inserted right below this intended br element. They are just two plain br tags with no style or class.



What could be causing this? This is a JSF, SEAM RichFaces application. I should add the inserted br tags look like <br> so they would not pass the xhtml requirements of facelets.

 
Tim Holloway
Saloon Keeper
Posts: 18304
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No way I can tell - it's probably generated by the <s:div> tag, whatever that is - but there's no need for <p/> or <br/> tags anyway. Use the margin-top and margin-bottom styles on your <div;> element to get the blank "lines" above and below the div content. Merely employing a div element causes the same effect as a br element, since the difference between div and span is that span doesn't do a line break.
 
Dan Acuff
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Turned out by changing the <P> tags to <s:div> tags around each section. The mysterious problem went away. Well most of it anyway.

In Internet Explorer If you click the Paypal radio button then Credit Card radio button then Paypal radio button, at that point it will automatically shift back to the Credit Card radio button on its own.

Something to do with the Ajax calls I am guessing..
 
Dan Acuff
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BUG:
When you select paypal it is fine, when you go back to credit card it is fine.. when you click yet again on PayPal's radio button it will automatically reselect the Credit card radio button. This only happens in IE browsers; Chrome and FF are fine.



and the 2 pieces that call the function:



and

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic