Centering Problem With HTML Editor - and so many more problems

Centering Problem With HTML Editor - and so many more problems

by Matt Thomas -
Number of replies: 3
Moodle is such a fantastic thing...with one exception...and it makes me want to pull my hair out on a daily basis: the HTML editor has soooo many problems.

1. My main problem is that when I enter text in it, using Firefox, it shows up left justified, as desired, and then when I see the page in IE, the text is shows centered or right justified. This problem does not happen with forum posts. I have to then set all the text to right justified and then back to left, and then usually it fixes that page.
2. The font face, size, and style are usually not correct for selected text. And if the values shown in the face, size, or styles boxes are what I WANT the selected text to be, I have to change it to something else and then change it right back. Then it will actually set the selected text accordingly.
3. PHP code manually entered is stripped.
4. If I manually tweak the HTML, the editor usually just messes with it. Drives me up the wall.
5. The editor loves to insert <p> tags for me. How lovely. That's when I actually start hitting my head against the wall.

If I can at least get #1 fixed, I would be happy. Anyone else have that problem?
Average of ratings: -
In reply to Matt Thomas

Re: Centering Problem With HTML Editor - and so many more problems

by Lady 800cc -

"...  5. The editor loves to insert <p> tags for me. How lovely. That's when I actually start hitting my head against the wall. ..."

This is the one that drives me INSANE!!!!!

In reply to Matt Thomas

Re: Centering Problem With HTML Editor - and so many more problems

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Matt > 5. The editor loves to insert <p> tags for me.

This is quite normal behavior: by pressing the Enter key you are asking the HTML editor to create a new paragraph (same as you would in a Word processor).

Now, your question really is "why are default paragraphs in the Moodle HTML editor so widely vertically spaced?" If you want paragraph vertical spacing to be reduced, you'll have to use the appropriate rule in your current theme.

Here is an example, for forum posts:

.forumpost td.content p {
  margin-top:0.6em;
  margin-bottom:0.6em;
}

Hope that helps,


In reply to Joseph Rézeau

Re: Centering Problem With HTML Editor - and so many more problems

by Matt Thomas -
Thanks, maybe that will help if I have problems with forum posts, but that is not really where I suffer so much frustration. It is in HTML pages. If I do something as simple as highlight some text and change the font, the editor will insert the <p> tags. It seems to force them on me.