2 Replies Latest reply: Jun 10, 2009 9:47 AM by dongle RSS

    Image alignment

    dongle Community Member

      Just upgraded to DWCS4. Started editing one of my sites and inserted and image into a div. In CS3 there were icons to select the image position such as align center, align right etc. These no longer appear for images but do for text.

       

      Am I missing something ?.

        • 1. Re: Image alignment
          David_Powers CommunityMVP

          If you want to align an image the old fashioned way, select Left or Right from the Align menu at the bottom right of the Property inspector.

           

          A much better way is to use CSS. Create the following three style rules:

          .floatleft {
            float:left;
            margin:3px 8px 3px 0;
          }
          .floatright {
            float:right;
            margin:3px 0 3px 8px;
          }
          .imgcentered {
            margin:3px auto;
            display:block;
          }
          

           

          Apply the appropriate class to the image using the Class menu instead. As long as the image has a width declared in the HTML, the imgcentered class will centre the image.

          • 2. Re: Image alignment
            dongle Community Member

            Many thanks for your reply. I have been using css where possible but it is still a learning curve for me. Picked up the "align center" option in previous versions and have used it for quick updates to my diary. Thanks for showing me the correct alternative