Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

cr-lf missing from my product descriptions


freegeek

Recommended Posts

Posted

As the topic title says, all of my product descriptions in my store are shown as plain test without any new lines being inserted where I want them. Is there any way to overcome this problem?

 

Thanks

Posted

If you simply output (in HTML) a bunch of lines, the browser will glue them together into one long paragraph.

This is line 1.

This is line 2.

This is line 3.

becomes

This is line 1. This is line 2. This is line 3.

You need to explicitly tell the browser where to break the text, either with <br> or with <p>...</p> tags. Be careful to check whether the code lets HTML tags through unscathed, or mangles them to displayable form (e.g., <br>).

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...