![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||||
| |||||
|
|
HikksNotAtHome wrote: When I try to move the Up/Down Arrow over to the right, as in this page: http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html IE6 and Opera7 display it as I want it. Mozilla 1.4, NS7, and Firebird give me something that totally baffles me where the arrows stagger across the screen. In your style, you have .leftText{ float:left; } .rightText{ float:right; } Floated elements are taken out of the normal document flow. Since both span elements in the div?header are floated, the parent div element takes no vertical space. The div? below it then takes its place, if you see what I mean. AFAICS, Mozilla gets it right. |
|
The default text-alignment is left, so there is no need to float the text left. Try removing that, keep the arrow floated right, and it should come out ok in Moz. |
|
BTW, you also have #div1{display: block;background: #0000ff;width: 20em;color: #ffffff;} #div2{display: block;background: #0000ff;width: 20em;color: #ffffff;} #div3{display: block;background: #0000ff;width: 20em;color: #ffffff;} ... 1. the default display for div is block, so there is no need to explicitly put display: block in the stylesheet |
|
2. instead of repeating each div in a separate rule, you could have #div1, #div2, #div3 /* etc. */ {display: block;background: #0000ff;width: 20em;color: #ffffff;} |
|
The testPage.html validates for both HTML4.01 Strict and CSS2 at w3c's validator. I'll take your word for it. But the w3c validator says it doesn't understand the character encoding specified. Something amiss with AOL, I'd guess. |
#2
| |||
| |||
|
|
http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html When I take the align:left out, I get the Div 1 Header on one line, the image on the next. Whether I specify a span around that text or not, it puts it on a new line. |
|
When the text-alignment is removed, it does indeed let the next div go to the next line. But, it moves the image with it. |
|
The testPage.html validates for both HTML4.01 Strict and CSS2 at w3c's validator. I'll take your word for it. But the w3c validator says it doesn't understand the character encoding specified. Something amiss with AOL, I'd guess. This one has me stumped now. When I validate the online version, it does indeed fail. When I go to that page, simply right click>View Source, save it locally, and then validate the file at w3c, it validates. What gives? |
#3
| |||
| |||
|
|
* Links want to be real links. A link to "#" with js off is sure to confuse visitors. |
#4
| |||
| |||
|
|
HikksNotAtHome wrote: http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html When I take the align:left out, I get the Div 1 Header on one line, the image on the next. Whether I specify a span around that text or not, it puts it on a new line. Yes, of course. My bad. That's because when you float an element, it becomes block level, and thus its box will be generated below the div#header. When the text-alignment is removed, it does indeed let the next div go to the next line. But, it moves the image with it. Right align the text, then float the first span left. May not work in IE. Test that and tell me how things look. While you're at it, fix some things. |
#5
| |||
| |||
|
|
http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html I did the above, and the image now site along side the header text (IE6 and NN7) but directly on its right, not at the far right end of the div header. Also, although this works, I don't see why floating the text left doesn't cause the same problem as floating the image right i.e. it becomes block level and therefore wants to be displayed below the header div? |
#6
| |||
| |||
|
|
http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html When the text-alignment is removed, it does indeed let the next div go to the next line. But, it moves the image with it. Right align the text, then float the first span left. I did the above, and the image now site along side the header text (IE6 and NN7) but directly on its right, not at the far right end of the div header. |
|
Also, although this works, I don't see why floating the text left doesn't cause the same problem as floating the image right i.e. it becomes block level and therefore wants to be displayed below the header div |
#7
| |||
| |||
|
|
http://members.aol.com/hikksnotathome/hideAndShowDivs/testPage.html Right align the text, then float the first span left. May not work in IE. Test that and tell me how things look. I did the above, and the image now site along side the header text (IE6 and NN7) but directly on its right, not at the far right end of the div header. |
#8
| |||
| |||
|
|
Links want to be real links. A link to "#" with js off is sure to confuse visitors. Or change it from # to javascript:; Even if visitors have javascript turned off, some will look in the statusbar and think "ooh, its javascript, so it wont work." |
|
I just hope that validates.. |
#9
| |||
| |||
|
|
Links want to be real links. A link to "#" with js off is sure to confuse visitors. Or change it from # to javascript:; Even if visitors have javascript turned off, some will look in the statusbar and think "ooh, its javascript, so it wont work." |
|
I just hope that validates.. |
#10
| |||
| |||
|
|
http://validator.w3.org/checklink?uri=http://www-unix.oit.umass.edu/~btre mbla/test/test2/jstest.htm |
![]() |
| Thread Tools | |
| Display Modes | |
| |