Page 99 - 2611_SmartGPT Pro V(5.0) C-7
P. 99

To run the provided HTML code successfully, you will need two additional HTML files that the
                 iframe elements will load. These files are specified by the src attributes in the iframe tags.

                   Frame1.html: This is the file that will be loaded into the first iframe.
                   Frame2.html: This is the file that will be loaded into the second iframe.




                           iFRAMES AND CSS

                 Let's learn the properties of CSS to make frames attractive.

                 HEIGHT AND WIDTH PROPERTIES
                 We can also use the style attribute and use CSS height and width properties to control the frames.

                 Example:

                 <!DOCTYPE HTML>
                 <HTML>
                 <HEAD>
                 <TITLE> iframes Example </TITLE>

                 <STYLE>
                 Body {Background-Color:Blue}
                 </STYLE>
                 </HEAD>
                 <BODY>

                 <H1 STYLE = "text-align:center"> Example of double spread containing
                 inline frames </H1>
                 <iframe src = "Frame1.html" Style="Height:200px;Width:200px;" Title =
                 "iframe Example"> </iframe>
                 <iframe src = "Frame2.html" Style="Height:200px;Width:200px;" Title =
                 "iframe Example"> </iframe>
                 </BODY>
                 </HTML>





















                 The web browser displays the inline frames.



                                                                                   Images, Links and Forms in HTML5  97
   94   95   96   97   98   99   100   101   102   103   104