nemakuphp Posted March 11, 2010 Report Share Posted March 11, 2010 Ir izveidots floating footer pēc netā atrastas pamācības. Viss ir ok, bet ir nepieciešams elementam #content iekš #container piešķirt height, lai tas aizpilda visu brīvo laukumu līdz #footer. HTML <div id="container"> <!-- te vel kadi elementu -!> <div id="content"> </div> </div> <div id="footer"> </div> CSS #container{ min-height: 100%; height: auto !important; height: 100%; margin-bottom: -104px; } #content{ min-height: 100%; height: auto !important; height: 100%; width: 1000px; margin: 0 auto; } #footer{ width: 1000px; height: 104px; background: #292929; margin: 0 auto; } Pēc manām domām, #content itkā vajadzētu izplesties, bet tas nenotiek Ceru, ka spēsiet palīdzēt Quote Link to comment Share on other sites More sharing options...
2easy Posted March 11, 2010 Report Share Posted March 11, 2010 html, body arī vajag height: 100% Quote Link to comment Share on other sites More sharing options...
nemakuphp Posted March 11, 2010 Author Report Share Posted March 11, 2010 Tiem ir abiem 100% Quote Link to comment Share on other sites More sharing options...
2easy Posted March 11, 2010 Report Share Posted March 11, 2010 min-height nestrādā, ja kādam parentam jau ir min-height Quote Link to comment Share on other sites More sharing options...
vitao.web Posted March 11, 2010 Report Share Posted March 11, 2010 Vel varetu izmeginat: height: auto; Quote Link to comment Share on other sites More sharing options...
nemakuphp Posted March 12, 2010 Author Report Share Posted March 12, 2010 Kā tad man būtu jāveido mans CSS? Jo ja #container noņemu min-height, tad viņš vairāk neizstiepjas un līdz ar to pazūd tas floating footer. Quote Link to comment Share on other sites More sharing options...
2easy Posted March 12, 2010 Report Share Posted March 12, 2010 ar height: 100% Quote Link to comment Share on other sites More sharing options...
nemakuphp Posted March 12, 2010 Author Report Share Posted March 12, 2010 Kuram elementam tieši? Jo vai tad viņš stiepsies, ja būs dots height 100%? Quote Link to comment Share on other sites More sharing options...
2easy Posted March 12, 2010 Report Share Posted March 12, 2010 jā. vnk tev šobrīd ir height: auto, jo !important ir lielāka prioritāte min-height lieto tikai pašam visiekšējākajam blokam, lai tad, kad lapa ir augstāka par ekrāna augstumu, lai pat tad tā noietu līdz apakšai Quote Link to comment Share on other sites More sharing options...
nemakuphp Posted March 12, 2010 Author Report Share Posted March 12, 2010 Paldies, laikam viss sanāca ;) Varat slēgt Quote Link to comment Share on other sites More sharing options...
2easy Posted March 12, 2010 Report Share Posted March 12, 2010 "laikam" :D:D:D tas bija ļoti pārliecinoši :P Quote Link to comment Share on other sites More sharing options...
nemakuphp Posted March 12, 2010 Author Report Share Posted March 12, 2010 :D Reāli viss notiek, neesmu vienīgi pārbaudījis kā ar stiepšanos ;) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.