caillon%returnzero.com c8612ff038 Bug 38370.
Allow color of an HR element to be changed.
Make HR be a block element in quirks mode instead of the hacky inline we were previously using (standards mode already had it as a block).
Patch by Ian Hickson <ian@hixie.ch> with minor modifications by me.
r+sr=bzbarsky@mit.edu


git-svn-id: svn://10.0.0.236/trunk@145375 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-30 08:13:07 +00:00

37 lines
1.3 KiB
HTML

<HTML>
<BODY>
<IMG src="resource:/res/samples/raptor.jpg" STYLE="float: left;">
<IMG src="resource:/res/samples/raptor.jpg" STYLE="float: right; height: 100px;">
This text should appear between a left justified and right justified image of a raptor.<BR clear="all">
Resize the window such that this paragraph is located between the two images. Then
use the form below to change the "clear" attribute of the BR tag that adds a line break
between this para and the previous one. Clearing to left should position this para below
the big raptor. Clearing to the right or clearing all should position this para below the
smaller raptor image.
<FORM>
<P>
Set <I>clear</I> to
<SELECT SIZE="1" NAME="clear">
<OPTION VALUE="none">None</OPTION>
<OPTION VALUE="left">Left</OPTION>
<OPTION VALUE="right">Right</OPTION>
<OPTION SELECTED VALUE="all">All</OPTION>
</SELECT>
<INPUT TYPE="button" VALUE="Change Clear" onClick="changeClear(); return true;">
</P>
</FORM>
<SCRIPT>
var br = document.getElementsByTagName("br")[0];
function changeClear() {
if (document.forms[0].clear.selectedIndex == 0)
br.clear = "none";
else if (document.forms[0].clear.selectedIndex == 1)
br.clear = "left";
else if (document.forms[0].clear.selectedIndex == 2)
br.clear = "right";
else
br.clear = "all";
}
</SCRIPT>
</BODY>
</HTML>