Page 67 - DCAP408_WEB_PROGRAMMING
P. 67

Unit 2: Creating Static Web Pages




                 </HEAD>                                                                        Notes
                         <FRAMESET  rows=”33%,33%,33%”>
                                     <FRAMESET  cols=”50%,50%”>
                                      <FRAME name=”frame1">
                                          <FRAME  name=”frame2">
                         </FRAMESET>
                         <FRAME  name=”frame3">
                 <FRAME  name=”frame4">
                 </FRAMESET>
                 <BODY>
                 ...contents  to  display  in  non-frame-capable  user  agent...
                 </BODY>
          </HTML>

          Try to remember the following basic frameset concepts:

              The opening FRAMESET tag defines the actual size and layout of the frames.
              Using the ROWS and COLS attributes of the FRAMESET tag, you define frames, then fill
               them with the FRAME element, or subdivide them with nested FRAMESET elements.

              The number of entries in ROWS or COLS attribute values determine how many frames are
               displayed and what size they are. If you have both ROWS and COLS, multiply the number
               of entries in each attribute value to calculate the total number of frames (i.e., three entries in
               the ROWS attribute and four entries in the COLS attribute create a grid of twelve frames).
              The FRAME elements fill the frames defined by FRAMESET, and are applied in the frame
               set in a left-to-right, top-to-bottom order.
              FRAME elements which include the SRC attribute, define the contents of each frame you
               create.
              Frames are always rectangular.

          The FRAMESET Element

          A frameset divides the browser window into rectangular regions. Each such region can be:
              A frame, which displays one document. A frame is represented by a FRAME element.
              Another frame set, which is itself further divided into frames.


                 Example: A frame set can contain a frame, plus another frame set containing two frames,
          resulting in three frames in all.
          An HTML  document  that  contains frames  basically  replaces  the BODY  element  with  the
          FRAMESET element.

              The Rows and Cols Attributes
               The attributes of the FRAMESET element are COLS (columns) and ROWS. They determine
               how many frames the frame set is divided into. These attributes may be blank, or may
               consist of a list of one or more values separated by commas or spaces. Each such value



                                           LOVELY PROFESSIONAL UNIVERSITY                                   61
   62   63   64   65   66   67   68   69   70   71   72