3 Replies Latest reply on Jul 18, 2006 5:35 PM by Steve Lawrie

    Div tag, align right

    Steve Lawrie
      Hello,

      This should be easy and for some reason I'm missing it. This is a php page and it has a Fireworks navigation panel on the lefthand side but I'm removing all the extranuous stuff just to leave the div tags which are governed by a CSS page.


      Why doesn't it do it? And, is there a way of controlling it with CSS?

      Thanks
        • 1. Re: Div tag, align right
          Level 7
          I have no idea what it is you are asking. If you want the image in the
          'mastkead' <div> to align right using css then use this:

          #masthead {
          text-align: right;
          }


          <div id="masthead"><img src="assets/masthead.jpg"></div>



          Steve Lawrie wrote:

          > Hello,
          >
          > This should be easy and for some reason I'm missing it. This is a php page and
          > it has a Fireworks navigation panel on the lefthand side but I'm removing all
          > the extranuous stuff just to leave the div tags which are governed by a CSS
          > page.
          >
          >
          > Why doesn't it do it? And, is there a way of controlling it with CSS?
          >
          > Thanks
          >
          > <html>
          > <head>
          > <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
          > <title>Ultra Music</title>
          > <link href="audience.css" rel="stylesheet" type="text/css">
          >
          > </head>
          >
          > <body
          > onLoad="MM_preloadImages('assets/menu/back_r2_c2_f2.jpg','assets/menu/back_r4_c2
          > _f2.jpg','assets/menu/back_r6_c2_f3.jpg','assets/menu/back_r6_c2_f2.jpg','assets
          > /menu/back_r8_c2_f3.jpg','assets/menu/back_r8_c2_f2.jpg')">
          > <div id="page">
          > <div id="nav">
          > </div>
          > <div id="masthead" align="right"><img src="assets/masthead.jpg"></div> <!--
          > This is the offender -->
          > <div id="content">
          > content
          > </div>
          > </div>
          > </body>
          > </html>
          >

          • 2. Re: Div tag, align right
            Steve Lawrie Level 1
            Ah..! that makes sense but for some reason the image is staying on the lefthand side. I would show you the link but it's a protected page and will ask you for a username and password.

            No matter how where I put the "align right or center" value, it remains on the left.

            Thanks
            • 3. Re: Div tag, align right
              Steve Lawrie Level 1
              The problem was in the CSS. I had padding set for the "content" div and nothing for the "nav" div. For some reason it was effecting the "nav" div. I have set padding for the "nav" div and taken the padding of the top of the "content" div, now the page presents properly.

              Thanks for the help Osgood..!