Issue Details (XML | Word | Printable)

Key: MDLSITE-685
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Martin Dougiamas
Reporter: Tim Hunt
Votes: 3
Watchers: 3
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle.org Sites

In the moodle.org forums, indenting does not work

Created: 19/Mar/09 12:31 PM   Updated: 22/Oct/09 03:02 PM
Return to search
Component/s: moodle.org

Issue Links:
Duplicate
 

Participants: Helen Foster, Martin Dougiamas, Mauno Korpelainen and Tim Hunt
Security Level: None


 Description  « Hide
Steps to reproduce:

1. Make a forum post.
2. In the HTML editor, use the indent button to indent a paragraph
3. Save.

Actual result:

The indent is lost.

Expected result:

Well Duh!

------

Looking, It seems that the HTML editor adds a <div style="margin-left: 40px;"> to do the indent, and Moodle then strips out the style attribute.

Also, if you try, as a work-round, using a more semantic <blockquote> tag, it seems that the Moodle 2.0 stylesheet sets that to 0 indent, which is stupid.

 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
Tim Hunt added a comment - 19/Mar/09 12:33 PM
The Moodle2 theme also breaks <dl> formatting. If designers insist on using a browser styles reset script then they must ensure that they put back sensible formatting for all HTML elements.

Mauno Korpelainen added a comment - 19/Mar/09 04:43 PM
I agree - it's the same problem as

http://tracker.moodle.org/browse/MDLSITE-681 (fixed already)

http://tracker.moodle.org/browse/MDLSITE-553 and http://tracker.moodle.org/browse/MDLSITE-561 (font tags can be used in editor but formatting is lost)

I could add to this list valid xhtml elements <big> and <small> (reset.css resets also these) but I have never seen them used here (moodle.org) because people usually change font size instead of using xxxx <big>yyy</big> xxx <small>zzz</small>


Helen Foster added a comment - 19/Mar/09 08:17 PM
Tim, thanks for your report, and Mauno, thanks for your comments.

Reassigning to our moodle2 theme tweaker...


Helen Foster made changes - 19/Mar/09 08:17 PM
Field Original Value New Value
Assignee Helen Foster [ tsala ] Martin Dougiamas [ dougiamas ]
Mauno Korpelainen added a comment - 19/Mar/09 08:30 PM
One more add - of course that reset.css breaks also other lists like

<ol>
<li>Coffee</li>
<li>Milk</li>
</ol>

or

<ul>
<li>Coffee</li>
<li>Milk</li>
</ul>

So

dl, dt, dd, ol, ul, li,
+ big and small

should probably be also totally removed from those first css tags mentioned in http://tracker.moodle.org/browse/MDLSITE-681 unless Urs gives them new css elsewhere in css. If no css is given those tags should use browser default css so resetting styles to "normal text" is not reasonable.


Mauno Korpelainen added a comment - 19/Mar/09 08:40 PM
...and I forgot that

blockquote

that Tim mentioned.


Mauno Korpelainen added a comment - 19/Mar/09 08:54 PM
...and one more comment

I just checked a forum post and those ol, ul and li tags are defined in css of moodle.org elsewhere - only dl, dt, dd, blockquote, big and small seem to be undefined.


Mauno Korpelainen added a comment - 19/Mar/09 09:37 PM
Finally <big> and <small> are not even in $ALLOWED_TAGS in weblib.php so moodle would cut them anyway if somebody tried to use them.

Helen Foster made changes - 22/Oct/09 02:54 PM
Link This issue is duplicated by MDLSITE-814 [ MDLSITE-814 ]
Helen Foster added a comment - 22/Oct/09 03:02 PM
Increasing the priority of this issue in the hope that it can be fixed soon to prevent further annoyance (see linked issue).

Helen Foster made changes - 22/Oct/09 03:02 PM
Priority Minor [ 4 ] Major [ 3 ]