Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Jun 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation need help inserting a div relative to another div

    Hi I'm a relative newbie here....know just enough to get myself into a lot of trouble. I am using a great template so I haven't had to learn much code.

    I have an image in a div that serves as our page header. What I want to do is add another div with text in it and have it positioned relative to that image. From what I can gather so far I need to position the new div relative to the "parent" div, but I don't know how to do that. I'm sure it's easy once you know!

    Of course I need to get this figured out ASAP as I have a deadline, so any help is appreciated. Thank you!!!!

  • #2
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,667
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Hello betise,
    It would be no problem to put your text wherever you want in relation to your header image... you'll just need to be more specific where you want it.

    Maybe you could photoshop an example? A scan of a drawing done by hand maybe? A link to the site with a more specific description of where the text should be place might be best...
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • #3
    New to the CF scene
    Join Date
    Jun 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    problem solved - thanks

    Thanks so much for your reply. I actually figured it out last night. I just needed to hop up to the code and move the div with my text inside the div that holds my image and THEN change the position to relative. I'd post a link, but the site isn't live yet.

  • #4
    New to the CF scene
    Join Date
    Jun 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Okay, I finally got all the divs where I want them, but I've ended up with way too much white space at the top of my page. Can anyone help me figure out my problem?



    Hopefully I've copied in enough of the code to see what I've done:



    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    <!--#Begineditable "doctitle" -->

    <title>Untitled Document</title>

    <meta name="keywords" content="keyword 1, keyword 2, keyword 3, etc.">
    <!-- #Endeditable -->

    <script type="text/javascript" src="../p7pm/p7popmenu_crv.js"></script>
    <style type="text/css" media="screen">
    <!--
    @import url("../p7pm/p7pmv0.css");
    -->
    </style>
    <link href="../p7curvitude/p7CRVboxes982_2col.css" rel="stylesheet" type="text/css" />
    <link href="../p7curvitude/p7CRV_PMMvert.css" rel="stylesheet" type="text/css" />
    <link href="../p7curvitude/p7CRV02.css" rel="stylesheet" type="text/css" />
    <!--[if lte IE 6]>
    <style>
    #p7PMnav a {background-image: none !important; padding: 6px 10px !important;}
    #p7PMnav a:hover, #p7PMnav .p7PMon {background-color: #010101 !important;}
    #p7PMnav ul {border: 1px solid #FFF;}
    #p7PMnav ul li {filter: alpha(opacity=90);background-color: #FF9900;}
    #p7PMnav .p7PMtrg, #p7PMnav .p7PMon {background-image: url(p7pm/img/p7PM_light_east.gif) !important;
    background-repeat: no-repeat;background-position: right center !important;}
    </style>
    <![endif]-->
    <style type="text/css">
    <!--
    .style1 {color: #000033}
    #apDiv1 {
    position:relative;
    left:150px;
    top:160px;
    width:847px;
    height:18px;
    z-index:1;
    }
    .style2 {
    color: #FFAE26;
    font-size: 12px;
    }
    .style3 {font-size: 10px}
    #apDiv2 {
    position:absolute;
    left:81px;
    top:595px;
    width:204px;
    height:99px;
    z-index:2;
    }
    #apDiv3 {
    position:absolute;
    width:242px;
    height:115px;
    z-index:2;
    left: 332px;
    top: 37px;
    }
    #apDiv4 {
    position:absolute;
    left:662px;
    top:-1px;
    width:334px;
    height:59px;
    z-index:2;
    }
    #apDiv5 {
    position:absolute;
    left:751px;
    top:180px;
    width:303px;
    height:30px;
    z-index:2;
    }
    .style8 {color: #EEB40A}
    .style9 {font-size: 12px}
    #apDiv6 {
    position:relative;
    width:300px;
    height:30px;
    z-index:3;
    left: 660px;
    top: 37px;
    }
    .style10 {
    color: #F7B413;
    font-size: 12px;
    }
    #apDiv7 {
    position:relative;
    left:55px;
    top:150px;
    width:190px;
    height:103px;
    z-index:4;
    }
    #apDiv8 {
    position:relative;
    left:37px;
    top:137px;
    width:223px;
    height:75px;
    z-index:4;
    }
    -->
    </style>
    <!-- TemplateParam name="OptionalImage" type="boolean" value="true" --><!-- TemplateParam name="Image Locaction" type="URL" value="../p7curvitude/img/original tech-wheel-for-sidebar.gif" -->
    <script src="../Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
    </head>
    <body onload="P7_initPM(0,0,1,-20,10)">




    <div id="masthead">

    <div id="apDiv8"><img src="../p7curvitude/img/Merrill_Logo.jpg" alt="MTA logo" width="186" height="96" /></div>

    <div>

    <div class="style2 style3" id="apDiv1">
    <style type="text/css">
    A:link {text-decoration: none; color: #FFAE26;}
    A:visited {text-decoration: none; color: #FFAE26;}
    A:active {text-decoration: none}
    A:hover {font-weight: bold; color: white;} </style>
    Visit our complete Design Center with
    <a href="../lanwanwifi.html">LAN / Wireless</a> /
    <a href="../voip.html">VOIP</a> /
    <a href="../avcomm.html">AV</a> /
    <a href="../security.html">Security</a> /
    <a href="../structuredcabling.html">Structured Cabling and Fiber-Optic</a>
    systems for new construction and retrofit projects of all sizes.</div>


    <div id="apDiv6">
    <div align="right" class="style10">PLANNING, DESIGN &amp; PROJECT MANAGEMENT OF TECHNOLOGY INFRASTRUCTURE</div>
    </div>

    </div>
    <div id="logo"> <div><img src="../p7curvitude/img/headerdraft.jpg" alt="header" width="958" height="127" /></div>
    </div>


    </div>
    <div class="c2_982" id="columnwrapper">
    <div id="columntop">&nbsp;</div>
    <div id="c1">
    <div id="pmm_wrapper">
    <ul id="p7PMnav">
    <li><a href="../index.html">Home</a></li>


  •  

    Tags for this Thread

    Posting Permissions

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