scottybwoy Posted April 22, 2008 Share Posted April 22, 2008 Hi, I have played around with this page and have narrowed down my problem to be a html one. I have used a <p> element to clear the bottom of my divs. This works fine if an even number of divs sit with each section of the page. I believe this is down to the <p> element and more to the point, my post <h2> element, both having the feature of sitting under the element to the left and using the available space to the right for the elements content. Is there a way around this, possibly to make it act as a block element? Please look at this page and it's source to see how it is displayed, thanks. Quote Link to comment https://forums.phpfreaks.com/topic/102305-block-element-diagnosis/ Share on other sites More sharing options...
ToonMariner Posted April 22, 2008 Share Posted April 22, 2008 http://www.webtoolkit.info/css-clearfix.html Quote Link to comment https://forums.phpfreaks.com/topic/102305-block-element-diagnosis/#findComment-523816 Share on other sites More sharing options...
scottybwoy Posted April 22, 2008 Author Share Posted April 22, 2008 Thanks toonmariner, I was sort of attempting that with my p elem, the reason I just used clear right, is that it moves everything to below my left nav bar. Is there a better way of arranging this? Quote Link to comment https://forums.phpfreaks.com/topic/102305-block-element-diagnosis/#findComment-523833 Share on other sites More sharing options...
ToonMariner Posted April 22, 2008 Share Posted April 22, 2008 mate - I've seen the html behind this a few times now - in all honesty from the first time you showed me - if at that point you had decided to start again with good semantic html - and got rid of all those awful conditional comments to insert html for ie6 - you'd have finished by now (that includes the learning process too!). This is a pretty good example of those rare occasions when persisting with what has been produced (because it is thought fixing what you have will be quicker than a complete re-work) is detrimental to the over all project. For everysecond this site remains 'off-line' is another second of lost income. I suspect that even now you'd be better off starting again... Sorry dude but there is too much to fix... Quote Link to comment https://forums.phpfreaks.com/topic/102305-block-element-diagnosis/#findComment-523884 Share on other sites More sharing options...
scottybwoy Posted April 22, 2008 Author Share Posted April 22, 2008 Yeah, I have been doing allot of research today on css and best practices and note that allot can be changed for the better. In fact I don't think it would be that difficult to change as the main layout is just a single template and the css is already separated over 4 sheets (general, content, topnav, leftnav). I have learned that clearfix needs to be used under all floats, and what I really need to do is stick my template images in the background, use transparent pixels for links, and use a layout that doesn't use floats. I found this one to be the most appropriate. I'll try to incorporate that. Do you have any good links for making my nav bars without using conditional comment blocks and if poss using pure css (no images). Quote Link to comment https://forums.phpfreaks.com/topic/102305-block-element-diagnosis/#findComment-524057 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.