SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Thread: Heigh Problem

  1. #1
    SitePoint Wizard nofel's Avatar
    Join Date
    Aug 2007
    Location
    Earth
    Posts
    1,766
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Unhappy Heigh Problem

    Hi all,
    I am new to css and i am good at it but i am having a problem. i have a div called copyright which ofcourse comes at bottom of the bottom or where the content of website ends. now i got many pages in which some text are long as some are too short but the div named copyright have a static position i.e
    Code CSS:
    #copyright{
    	background-image:url(images/cr_bg.jpg);
    	background-repeat:repeat-x;
    	width:788px;
    	height:50px;
    	text-align:center;
    	left:150px;
    	position:absolute;
    	top: 1040px;
    	padding-top:10px;
    	border:1px #333333 dotted;
    	}
    Now when the text is too long. this div overwrites the text or if the text is too short the div is far below. is there anyway in which the copyright div adopts the height of the above div to adjust itself?

    Thanks in advance

  2. #2
    SitePoint Wizard bronze trophy Centauri's Avatar
    Join Date
    May 2007
    Location
    Newcastle, Australia
    Posts
    3,718
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Read this post by Paul O'Brien - absolute positioning will remove the footer from the document flow, so it is unaffected by anything else on the page.

  3. #3
    SitePoint Member
    Join Date
    Nov 2007
    Posts
    7
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Please try below

    #copyright{
    background-image:url(images/cr_bg.jpg);
    background-repeat:repeat-x;
    width:788px;
    height:50px;
    text-align:center;
    padding-top:10px;
    border:1px #333333 dotted;
    float: left;
    }


    Or



    #copyright{
    background-image:url(images/cr_bg.jpg);
    background-repeat:repeat-x;
    width:788px;
    height:50px;
    text-align:center;
    padding-top:10px;
    border:1px #333333 dotted;
    }


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •