Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

'Absolute' problem - please help

Status
Not open for further replies.

Seminara

Technical User
Jun 9, 2005
36
GB
Hi all

Please have a look at the following:


I was hoping to have the clock image move with the rest of the content area but it's instead remaining stationary.

Can you spot the problem? Does it have anything to do with the fact that I've built the page to have a footer which hugs the browser bottom?

The link to my CSS is here:


Hope someone can help!

Thanks in advance,
Steiner
 
If you absolutely position an element then it's taken out of the document flow and will no longer affect or be effected by other page elements.

If you want it to move with the rest of the page content it needs to be part of that content or you will need a convoluted solution to recalculate it's position.

<honk>*:O)</honk>

Earl & Thompson Marketing - Marketing Agency Services in Gloucestershire
 
OK, I understand what you're saying - but how do I then get it to move with the rest of the column - short of cutting the image up and inserting it table style?

All I want is the thing to sit on top of other DIVs. I thought CSS allowed this sort of layering to take place?
 
Try variations on
Code:
#clock {
	padding: 0 0 0 0;
	margin: 0 0 0 0;
	display: block;
	position: [b]static[/b];
	height: 198px;
	width: 184px;
	z-index: 8;
	top: 13px;
	visibility: visible;
	left: 633px;
	float: none;
}

Greg
"Personally, I am always ready to learn, although I do not always like being taught." - Winston Churchill
 
OK - I found a solution - though not what I'd originally intended. Absolute tagged divs seem to follow the content 'only' if that content is wrapped in a div which has a set width.

I originally had it set to 100% so all elements floated. Now I've changed that to 750px. Not perfect - but it works.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top