iEntry 10th Anniversary Forum Rules Search
WebProWorld
Register FAQ Calendar Mark Forums Read
Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Share Thread: & Tags

Share Thread:

Tags
css, div tags, positioning graphic

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-01-2009, 05:43 PM
sharonjackson's Avatar
WebProWorld Member
 
Join Date: Nov 2008
Location: Duncan, BC Canada
Posts: 66
sharonjackson RepRank 1
Default CSS problem..probably simple for somebody smart!

I am developing a website using a Dreamweaver template- 2 column fixed width. At the bottom of each page I want a graphic on the left.

Building Design - Unique Home Designs - Duncan - Vancouver Island BC

I can place it there, but it leaves a large white space to the right of it where the content cannot go. I tried putting the <div> right after the container tag, but it makes the graphic stay at the top and bumps the sidenav div over. Here is the code that does not work:

.twoColFixRtHdr #hand {
float: left; /* since this element is floated, a width must be given */
width: 156px;
height:258px;
background: #ffffff;
background-image:url(images/interface/lower_left_hand.jpg);
background-repeat:no-repeat;
z-index:100;
position:relative;
left:-200px;
}

This is what it is supposed to look like:



I could do this with my eyes closed using tables and I am about to throw in the towel, but will keep at it if someone can help me!!

Thank you so much
Reply With Quote
  #2 (permalink)  
Old 10-01-2009, 06:05 PM
Uncle Dog's Avatar
WebProWorld Pro
 
Join Date: Apr 2008
Location: Scotland
Posts: 254
Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5
Default Re: CSS problem..probably simple for somebody smart!

Quick look at your page source I'd say you should put the hand div inside the sidebar div. Don't worry about floating it, just position it.

Last edited by Uncle Dog; 10-01-2009 at 06:09 PM.
Reply With Quote
  #3 (permalink)  
Old 10-01-2009, 06:09 PM
sharonjackson's Avatar
WebProWorld Member
 
Join Date: Nov 2008
Location: Duncan, BC Canada
Posts: 66
sharonjackson RepRank 1
Default Re: CSS problem..probably simple for somebody smart!

I tried that, Uncle Dog, but if I have a page that has a lot of content, the hand graphic would stay at the bottom of the side nav links and the content would continue on down, leaving the graphic hanging on the left in the middle someplace rather than at the bottom.

Any other thoughts? Other than never putting a graphic on the bottom again????
Reply With Quote
  #4 (permalink)  
Old 10-01-2009, 06:10 PM
Uncle Dog's Avatar
WebProWorld Pro
 
Join Date: Apr 2008
Location: Scotland
Posts: 254
Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5
Default Re: CSS problem..probably simple for somebody smart!

Try a negative top value to pull it upwards?
Reply With Quote
  #5 (permalink)  
Old 10-01-2009, 06:48 PM
sharonjackson's Avatar
WebProWorld Member
 
Join Date: Nov 2008
Location: Duncan, BC Canada
Posts: 66
sharonjackson RepRank 1
Default Re: CSS problem..probably simple for somebody smart!

Nope...alas, that did not work either. I tried putting it back in the side nav div and giving it a negative number, but it is still too absolute. If I have a lot of content, it will only go as far as the side nav and not all the way to the bottom of the page. I should check out zengarden.com and see if I can find a solution there. I cannot afford to spend a lot of time on this, though, he is in a hurry and I am thinking I am going to throw in the towel and go to tables.
Reply With Quote
  #6 (permalink)  
Old 10-01-2009, 06:57 PM
Uncle Dog's Avatar
WebProWorld Pro
 
Join Date: Apr 2008
Location: Scotland
Posts: 254
Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5
Default Re: CSS problem..probably simple for somebody smart!

Got it.
Put the hand div immediately before the footer div. Then give the hand div a top:-220px ish value. Adjust to suit. It rides up and down with the footer.

Last edited by Uncle Dog; 10-01-2009 at 07:07 PM.
Reply With Quote
  #7 (permalink)  
Old 10-01-2009, 07:07 PM
sharonjackson's Avatar
WebProWorld Member
 
Join Date: Nov 2008
Location: Duncan, BC Canada
Posts: 66
sharonjackson RepRank 1
Smile Re: CSS problem..probably simple for somebody smart!

Just as you sent this I had tried putting the hand div right IN the footer div

.twoColFixRtHdr #hand {
float: left; /* since this element is floated, a width must be given */
width: 156px; /* the actual width of this div, in standards-compliant browsers, or standards mode in Internet Explorer will include the padding and border in addition to the width */
height:258px;
background: #ffffff; /* the background color will be displayed for the length of the content in the column, but no further */
background-image:url(images/interface/lower_left_hand.jpg);
background-repeat:no-repeat;
position: relative;
bottom: 212px;
z-index: 100;

}


and it works! Thank you so much for working with me on this one. What a little bugger it was!! Having someone work with me on it made all the difference.

That website by the way is www.csszengarden. It has some very cool stuff on it. There are a bunch of sites down the right hand side that all have the same content, but show you all the stuff css can do.
Reply With Quote
  #8 (permalink)  
Old 10-01-2009, 07:14 PM
Uncle Dog's Avatar
WebProWorld Pro
 
Join Date: Apr 2008
Location: Scotland
Posts: 254
Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5Uncle Dog RepRank 5
Default Re: CSS problem..probably simple for somebody smart!

No problem. Good night.
Reply With Quote
  #9 (permalink)  
Old 10-01-2009, 07:57 PM
danlefree's Avatar
WebProWorld Pro
 
Join Date: Jun 2005
Location: Seattle
Posts: 268
danlefree RepRank 4danlefree RepRank 4danlefree RepRank 4danlefree RepRank 4
Default Re: CSS problem..probably simple for somebody smart!

... and then there's the option to set the hand image as the page background with lower-left alignment
__________________
Dan LeFree | Product Manager (Linux VPS Hosting) | Owner/Operator (Web development, marketing)
Reply With Quote
  #10 (permalink)  
Old 10-03-2009, 03:21 AM
Moderator
WebProWorld Moderator
 
Join Date: Oct 2003
Location: Alberta, Canada
Posts: 878
weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6
Default Re: CSS problem..probably simple for somebody smart!

The sad truth is that the lower left and lower right corners are impossible to position without some strain and a little weirdness in two column layouts without tables. The left column is essentially the wrapper layer with width restrictions on its content (navbar, etc.) and the right is floated left with a margin ~+10px of the used width of the left side. Then the image is absolutely positioned in the wrapper layer, as well, pinned to the bottom. Now the footer is put in the wrapper with the same margin as the content and all is well.
Reply With Quote
  #11 (permalink)  
Old 11-20-2009, 12:12 PM
WebProWorld New Member
 
Join Date: Nov 2009
Posts: 1
agrable RepRank 0
Default Re: CSS problem..probably simple for somebody smart!

Since you've created a div on the left side, why not just fill up the remaining space on the right by creating a div on the right?
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Let's See How Smart You Are... Tiffany The Castle Breakroom (General: Any Topic) 12 09-29-2006 11:28 AM
Jagger or simple problem? jmoran77 Search Engine Optimization Forum 2 11-18-2005 10:29 PM
some simple MOD rewrite help - like its ever simple freehits Web Programming Discussion Forum 1 05-18-2005 01:25 AM
Simple problem ken71683 Web Programming Discussion Forum 1 02-04-2005 01:30 PM
Smart Spamming Theremin Google Discussion Forum 3 03-26-2004 09:50 PM


All times are GMT -4. The time now is 08:00 AM.



Search Engine Optimization by vBSEO 3.3.0