For discussion and questions related to CMS Specific templates and stylesheets (CSS), and themes. or layout issues. This is not a place for generic "I don't know CSS issues"
As you can see I have to either specify the height of the #navcontainer or as I am doing at the moment specify a large margin-top on #divLeftCol - or the #divLeftCol appears behind the menu div #navcontainer instead of below it. I would ideally like to specify min-height: 100% or height: 100% on #navcontainer but it doesn't seem to work. Have also tried float:left; clear:left on #divLeftCol.
So how do I make #divLeftCol always appear just below #navcontainer, no matter how big the menu grows?
Last edited by ladyr0gue on Tue May 01, 2012 9:24 pm, edited 1 time in total.
I tried that - need to add clear: left to the bottom div too (or specify width of #divLeftColWrapper as 240px)- but still need to specify menu height or margin height of #divLeftCol for it to appear below as they seem to be on top of one another! I have mucked it up somewhere haven't I...
here's the way the divs are nested
Sorry, I should have told you first off that it really helps to be able to see the page having trouble as there may be something else making it not work...
Dr.CSS wrote:Sorry, I should have told you first off that it really helps to be able to see the page having trouble as there may be something else making it not work...
ah you're too good. did you mean template or just whole page? sorry the project isn't live yet so can't send link but but my view source is as follows
The answer is not in here, so there's definitely something else going on. It's very hard to tackle these kind of problems without using webbrowser development tools so a live example would really help.
mcDavid wrote:The answer is not in here, so there's definitely something else going on. It's very hard to tackle these kind of problems without using webbrowser development tools so a live example would really help.
sure, thanks anyway - I will carry on thinking and if I still haven't figured it out will post a link when its live Its not a major issue as I can make the user able to modify pages and just edit the margin by hand when I add pages, but it's a niggle nonetheless
Hello my dears, just to say that I haven't yet found an answer to my problem - but I have just uploaded the site onto a folder on the live server so if you wouldn't mind having a look -
The div in question is divLeftCol, which contains div.news and sometimes images and it sits behind or on top of, rather than below the dynamic menu in the left column. As you can see I have had to give it's container divLeftCol a ridiculous top margin of 277px and should the user add any pages this will need to be edited manually or the menu will cover it.
it's not on the front page but on all of the following pages
edit: deleted url
thanks
Last edited by ladyr0gue on Tue May 01, 2012 6:51 pm, edited 1 time in total.
At the bottom of the nav div add <div style='clear:both;'></div>...
When you use 'position' on an element it may pull it above the layout, in your case it is the UL, when this happens the container it is in, #navcontainer, contracts till it hits something to hold it's shape and anything below it will slide up/slip under it...
Think of each 'box' as being stretchy like a rubber band that holds all of it's content in the 'box', when you float or position anything in it it's like you pull that item out of the box and hold it in place above the 'box' and the 'box' shrinks/contracts letting anything below it to move up, if you put a clear div at the bottom of the 'box' under the floated or positioned items it will hold it's shape...
I got all excited there and tried it - but for some strange reason its still not having it. tried putting it in the menu template, in the nav container div, and below it. both with "double quotes" and without. as you can see here, with only a 10px margin it's still hiding!
edit: deleted url
have I applied too much positioning in the menu css? I'm getting really stuck! help me please Dr....
Last edited by ladyr0gue on Tue May 01, 2012 6:51 pm, edited 1 time in total.