IE6 span line feed solves span float: right cannot be right-aligned, but display line feed
Example: how to solve the problem of right alignment of span. This method has been tested and can be correctly displayed on the same line in IE8 and Firefox browsers, in the 360 browser, the word "span right alignment problem" is displayed on the rightmost side of the next line. The reason and solution are as follows:
When the non-float element and the float element are together, if the non-float element comes first, the float element will be excluded.
That is to say, your span is float: Right, but the content in the previous H1 "How to Solve" is still float: None. If you want the text to occupy the same line, there are two solutions:
1. Place the question code with the right alignment of span in front
2. Set the float attribute for the previous text
Note: The code above in IE6 cannot be properly displayed today. The solution of IE6 is as follows:
Add a _ margin-top:-20px to the span after the span float: right (the value can be adjusted as needed), that is
How to solve the right alignment of Span