Module Three Quick Reference


Sounds :: Frames

  • Sounds
    There are several approaches to including sound in HTMl documents. Results seem to be largely browser-dependent. Some browsers will need to launch external programs tp play some types of audio, others will be handled internally. Most browsers shouls be able to accomodate MIDI, WAV, and AU files.
    The simplest approach is simply to create a link to the sound file you wish to play, using the <A>...</A> tag with the HREF option set to the filename.
    This requires the reader of your page to click the link to hear the sound. To create sounds which play automatically, you will need to experiment with the somewhat unpredictable <embed> tag. I accept no responsibility for the results, but it can be a very attention getting device.
    • <EMBED> (monoid)
      This allows you to embed a sound (actually, several types of multi-media) in your document.
      • SRC (="filename")*
        Defines file to use for the sound.
      • AUTOSTART (="TRUE" or "FALSE")*
        Determines whether the sound plays automatically upon loading the page.
      • LOOP (="TRUE", "FALSE", OR "X")
        Determines whether the sound loops indefinately, not at all, or X times, respectively.
      • HIDDEN = TRUE
        Specifies that the sound should be "invisible" on the page: the browser will display no page element for the sound, nor controls to start and stop the sound.
<A HREF="bam.wav">Make a Noise!</A>


<EMBED SRC="bam.wav" AUTOSTART=TRUE LOOP=TRUE>


  • Frames
    • <FRAMESET>...</FRAMESET>
      This container tag willenclose the tags defining each frame, just as the List tags enclose the <LI>...</LI> tags. One and only one of the following two parameters must be specified. The list of numbers indicates the size in Pixels, or in Percentage of Window, of each Frame. COLS specifies that the frames are arranged vertically, ROWS horizontally. Note that FRAMESETs may be nested, so for example, a vertical frame is divided into two horizontal frames.
      • COLS (="X, Y,..., Z" OR "X%, Y%,..., Z%")
      • ROWS (="X, Y,..., Z" OR "X%, Y%,..., Z%")
    • <FRAME> (monoid)
      This tag defines each frame. There must be one of these for each number in the FRAMESET.
      • SRC (="filename" or "URL")
        This specifies an HTML document to display in the frame.
      • NAME (="somename")
        This gives the frame a name which may be used to refer to it from elsewhere. This is most often used in conjunction with the TARGET="name" option availible in link anchors. This specifies that when the link is clicked, the named frame should be loaded with the HREF specified in the anchor, NOT the frame where the link was clicked, which will be unaffected.
<FRAMESET ROWS="40%,60%">
 <FRAME SRC="index.html">
 <FRAME SRC="class.html">
</FRAMESET>


<FRAMESET COLS="40%,60%">
 <FRAME SRC= "class.html" name="main">
 <FRAME 
   SRC = "course.html#sysllabus"
   NAME="view">
</FRAMESET>

We would then make all the links in class.html look like:

<A HREF="tag3.html TARGET="view">
blah blah</A>


<FRAMESET COLS="40%,60%">
 <FRAMESET ROWS="50%,50%">
   <FRAME SRC="index.html">
   <FRAME SRC="class.html">
 </FRAMESET>
 <FRAME SRC="course.html">
</FRAMESET>


SCS HTML Course Module Three