לאתר זה תהיה פונקציונליות מוגבלת בזמן שאנו מתחזקים אותו לשיפור החוויה שלך. אם מאמר מסויים לא פותר את הבעיה שלך וברצונך לשאול שאלה, קהילת התמיכה שלנו מחכה לעזור לך ב־Twitter תחת ‎@FirefoxSupport וב־Reddit תחת ‎/r/firefox.

חיפוש בתמיכה

יש להימנע מהונאות תמיכה. לעולם לא נבקש ממך להתקשר או לשלוח הודעת טקסט למספר טלפון או לשתף מידע אישי. נא לדווח על כל פעילות חשודה באמצעות באפשרות ״דיווח על שימוש לרעה״.

מידע נוסף

Firefox 4 element seems to gain top margin when only bottom margin is set.

  • 1 תגובה
  • 14 have this problem
  • 6 views
  • תגובה אחרונה מאת dponinski

more options

I've been working on blocking out a page layout, and after I upgraded to Firefox 4 I noticed that a central element containing 3 floating elements and a clearing div suddenly started gaining spacing where the top margin would be whenever the bottom margin was set. One can bypass the problem by either giving the clearing div a height somehow or by using padding instead, but I want to know if this is a bug or that I'm just missing something. This behavior is not duplicated in any other browser I've tried including IE6.

I have set up a demo at http://jacobanderson.us/projects/bugs/firefox4margintest.html - if you edit the bottom margin of the "body .page .content .keynote" element in Firefox 4 you'll see that the entire element gains spacing on both the bottom and top equally. The same effect can be triggered by adding a top margin to the "body .page .content .columns" element.

I've been working on blocking out a page layout, and after I upgraded to Firefox 4 I noticed that a central element containing 3 floating elements and a clearing div suddenly started gaining spacing where the top margin would be whenever the bottom margin was set. One can bypass the problem by either giving the clearing div a height somehow or by using padding instead, but I want to know if this is a bug or that I'm just missing something. This behavior is not duplicated in any other browser I've tried including IE6. I have set up a demo at http://jacobanderson.us/projects/bugs/firefox4margintest.html - if you edit the bottom margin of the "body .page .content .keynote" element in Firefox 4 you'll see that the entire element gains spacing on both the bottom and top equally. The same effect can be triggered by adding a top margin to the "body .page .content .columns" element.

כל התגובות (1)

more options

I seemed to have solved the issue with the margin on the top and bottom. Just float the header and footer left. You might need to clear left or right depending on your layout but that did the trick for me. Hope this helps.