Last modified: 2010-05-15 14:35:53 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T3920, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 1920 - Tables don't support the "nowrap" cell attribute
Tables don't support the "nowrap" cell attribute
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Page editing (Other open bugs)
unspecified
PC All
: Normal normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-04-18 22:06 UTC by Colin Burnett
Modified: 2010-05-15 14:35 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Colin Burnett 2005-04-18 22:06:31 UTC
Adding "nowrap" to a table cell or row should force the browser to not wrap
lines at spaces.  However, media wiki ignores these.  For example, putting this
in an article:

{| width="50"
|-
|nowrap|hello world
|}

<TABLE width="50">
 <TR nowrap>
  <TD nowrap>hello world</TD>
 </TR>
</TABLE>

will generate the following HTML:

<table width="50">
<tr>
<td>hello world</td>
</tr>
</table>
<table width="50">
<tr>
<td>hello world</td>
</tr>
</table>

which is clearly missing the nowrap attribute.  The only way to actually force
this is to replace all spaces with the "& nbsp ;" equivalent, which is nothing
short of a hack.
Comment 1 Brion Vibber 2005-04-18 22:17:19 UTC
The nowrap attribute is deprecated in HTML 4[1], and since we don't already support it we probably aren't going to add it.

Have you tried the equivalent CSS bit[2]?
Something like style="white-space:nowrap" should do it.


[1] http://www.w3.org/TR/html4/struct/tables.html#adef-nowrap
[2] http://www.w3.org/TR/CSS2/text.html#white-space-prop
Comment 2 Brion Vibber 2005-04-25 10:00:24 UTC
Actually, the updated HTML sanitizer code in 1.5 already allows this attribute. Resolving FIXED.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links