3 Replies Latest reply on Jun 7, 2010 3:45 AM by David_Powers

    divs + layers

    iconofsin14 Level 1

      I have been looking at many tutorials recently

       

      i believed that divs and layers were the same thing just 2 different words. but im not certain

      so are the the same or not

       

      and if not what is a layer?

        • 1. Re: divs + layers
          Nancy OShea Adobe Community Professional & MVP

          Not quite.  A Division is any CSS container.  APDivs or Absolutely Positioned Divisions were formerly called Layers because you could, in theory, use them to build pages that contained overlapping elements.   It was a nice idea but it failed to produce good cross browser results. You can read more about it below.

          http://apptools.com/examples/pagelayout101.php

           

          It is best to use default CSS positioning (which is no positioning at all) along with margins, padding and floats. Reserve the use of Absolutely Positioned Divisions for special situations such as modal windows (lightboxes), disjointed rollovers or drop menus.

           

           

          Nancy O.
          Alt-Web Design & Publishing
          Web | Graphics | Print | Media  Specialists
          http://alt-web.com/
          http://twitter.com/altweb
          http://alt-web.blogspot.com

          • 2. Re: divs + layers
            iconofsin14 Level 1

            Are there any CSS containers other than DIVs

            • 3. Re: divs + layers
              David_Powers Adobe Community Professional

              iconofsin14 wrote:

               

              Are there any CSS containers other than DIVs

              It depends what you mean by "CSS container". All HTML elements can be styled with CSS.

               

              The purpose of a <div> is to group together multiple elements in a single block. There is another generic container called <span> that applies a style to inline elements (such as a couple of words in the middle of a paragraph).

               

              When HTML5 is more widely supported, there will be other container-like elements, such as <header>, <nav>, <section>, and <aside>. But these are not currently supported by all browsers.