1

I'm building a website fro a client which uses TinyMCE as the main WYSIWYG editor. Now my client asked if it is possible to write a line and make a line break and then continue without leaving a space between the text before and after the line break (e.g. just like in word).

I told him that the web uses paragraph for formatting and not line breaks. Still he'd like to use line breaks for formatting. Should I convince him not to use line breaks for formatting or should I just switch TinyMCE to line break mode (which the is not recommended in the TinyMCE documentation).

2 Answers 2

0

Simply use the <br /> tag wherever you want a new line...

If tinyMCE doesn't have a button for that already, I remember it was dead simple to write plugins like that with a few lines of javascript.

Same as on SE, you can use it like this:

This should work <br />with no problems.

This should work
with no problems.

3
  • What do you mean by SE?
    – wowpatrick
    Aug 6, 2011 at 14:08
  • this site (or network of Q&A sites), SE = StackExchange Aug 6, 2011 at 14:10
  • See. Good to know.
    – wowpatrick
    Aug 6, 2011 at 14:11
0

Why not just set the CSS for <p> tags for the areas of the site you are concerned with so that they have no margin or padding?

.mycontent p{
    margin:0;
    padding:0;
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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