layout/html/tests/attributes/pre.html
author Honza Bambas <honzab@allpeers.com>
Fri, 10 Oct 2008 16:41:38 +0200
changeset 20258 097bf47abbcde2ba53c62212eca60c5cb5d9ce9d
parent 1 9b2a99adc05e53cd4010de512f50118594756650
permissions -rw-r--r--
Bug 413909 - nsCertOverrideService IDN handling is broken; tests; r=kaie

<HTML>
<BODY>
<PRE WIDTH="50">
This text is within a PRE tag.  This text is within a PRE tag.
This text is within a PRE tag.  This text is within a PRE tag.
This text is within a PRE tag.  This text is within a PRE tag.
This text is within a PRE tag.  This text is within a PRE tag.
This text is within a PRE tag.  This text is within a PRE tag.
</PRE>
<P>
Use the buttons below to change the width attributes for the preformatted text above.  
</P>

<FORM>
<P>
Set <I>width</I> to
<INPUT TYPE="text" NAME="width" VALUE="50">
<INPUT TYPE="button" VALUE="Change Width" onClick="changeWidth(); return true;">
</P>

</FORM>
<SCRIPT>
var pre = document.getElementsByTagName("pre")[0];
function changeWidth() {
   pre.width = Math.abs(document.forms[0].width.value);
}
</SCRIPT>
</BODY>
</HTML>