Opened 19 years ago
Closed 17 years ago
#2131 closed defect (bug) (fixed)
RTE align buttons use deprecated HTML attributes
Reported by: | seth | Owned by: | |
---|---|---|---|
Milestone: | 2.5 | Priority: | high |
Severity: | major | Version: | 2.0 |
Component: | TinyMCE | Keywords: | xhtml |
Focuses: | Cc: |
Description
When using the align buttons, they generate markup like:
<p align="center"></p>
It would be much better to have them use the style attribute:
<p style="text-align: center"></p>
Change History (18)
#3
@
18 years ago
- Component changed from Administration to General
- Keywords xhtml added
- Milestone changed from 2.5 to 2.2
- Summary changed from WYSIWYG align buttons use invalid markup to RTE align buttons use invalid markup
ENV: WP 2.1-alpha3 (r4198)
Yes, darkfate, using RTE, this still seems as described.
seth, what do you mean by "invalid markup"?
#4
@
18 years ago
- Summary changed from RTE align buttons use invalid markup to RTE align buttons use deprecated HTML attributes
It would be better to say that they use deprecated HTML attributes.
See:
http://www.w3.org/TR/html4/present/graphics.html#adef-align
#7
@
18 years ago
No, it's invalid markup in XHTML 1.0 Strict (and XHTML 1.1, etc.). Most themes use XHTML 1.0 Transitional and the align
attribute is only deprecated in Transitional.
#11
@
17 years ago
Note that the left/center/right align buttons have a different effect when used on images instead of paragraphs.
The align="left"
attribute works like style="float:left"
instead of style="text-align:left"
and the same goes for the right-align button (with float:right
obviously). This will need to be taken into consideration if this issue is to be fixed.
#12
@
17 years ago
What I mean to say is, when the left/right button is used on an image, the HTML which is inserted will need to be different (style="float:left"
instead of style="text-align:left"
).
#13
@
17 years ago
Reported upstream: text-align bug and image float bug
#15
@
17 years ago
- Milestone changed from 2.4 to 2.5
Still not addressed by TinyMCE tickets submitted by Nazgul should be pushed.
Is this still valid for 2.0.3?