Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

Revision 494829 of <nobr>

  • Revision slug: Web/HTML/Element/nobr
  • Revision title: <nobr>
  • Revision id: 494829
  • Created:
  • Creator: kscarfone
  • Is current revision? No
  • Comment

Revision Content

{{non-standard_header}}

Summary

The nobr tag prevents a text from breaking into a new line automagically, so it is displayed on one long line and scrolling might be necessary. This tag is not standard HTML and should not be used. Instead use the CSS property {{Cssxref("white-space")}} like this:

<span style="white-space: nowrap">Long line with no breaks</span>

See also

  • {{Cssxref("white-space")}}
  • {{Cssxref("overflow")}}
{{HTMLRef}}

Revision Source

<div>
 {{non-standard_header}}</div>
<h2 id="Summary" name="Summary">Summary</h2>
<p>The <code>nobr</code> tag prevents a text from breaking into a new line automagically, so it is displayed on one long line and scrolling might be necessary. This tag is not standard HTML and should not be used. Instead use the CSS property {{Cssxref("white-space")}} like this:</p>
<pre class="brush:css">
&lt;span style="white-space: nowrap"&gt;Long line with no breaks&lt;/span&gt;</pre>
<h2 id="See_also" name="See_also">See also</h2>
<ul>
 <li>{{Cssxref("white-space")}}</li>
 <li>{{Cssxref("overflow")}}</li>
</ul>
<div>
 {{HTMLRef}}</div>
Revert to this revision