Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Feb 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Defining 2 rows with border in a frameset

    I am having a lot of problems trying to get the 2 rows with a frameset and I don't know why. Where do I put the code? I have placed in all over and checked each time, and nothing works! I also need to have a seperate background color for the rows. I had to put 2 pages together to create this, am I suppose to have the html, head, etc. in twice? I have been trying to fix this since Sunday and I am totally lost!

    Thanks
    Shamrockdawn

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    Canada
    Posts
    253
    Thanks
    0
    Thanked 0 Times in 0 Posts
    frames = dividing the window into sections and displaying a different webpage in each section.

    if that is indeed what you want to accomplish, then yes, you need to create more than one webpage to get your desired results.

    one webpage will be holding your FRAMESET stuff to divide up the window.
    then you need X number of webpages to fill in each section. these are full, complete webpages as if they were being displayed on their own.

    does that clear things up at all?

  • #3
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    HI, and welcome to the wonderful world of webdesign, and this forum!

    Can you post your code, it would be easier if we could see what you're working with...

    It sounds to me as if maybe you're lost on how exactly a frameset works.

    Quick summary of frames

    framset.html (file which tells the browser which HTML file goes in the first column and which goes in the second):

    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <title>Untitled Document</title>
    </head>
    
    <frameset cols="80,*" frameborder="NO" border="0" framespacing="0">
      <frame src="navbar.html" name="leftFrame" scrolling="NO" noresize="noresize">
      <frame src="mainpage.html" name="mainFrame">
    </frameset>
    <noframes><body>
    You've GOT to get a newer browser!
    </body></noframes>
    </html>
    navbar.html: code for your navbar goes here.
    mainpage.html: code for your main area goes here.

    Here is a good article: W3 article on frames

    Dan

    I just realized that you were talking about ROWS not COLUMNS.
    Here is the code for two rows:

    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <title>Untitled Document</title>
    </head>
    
    <frameset rows="80,*" frameborder="NO" border="0" framespacing="0">
      <frame src="topframe.html" name="topFrame" scrolling="NO" noresize>
      <frame src="mainpage.html" name="mainFrame">
    </frameset>
    <noframes><body>
    You've GOT to get a newer browser
    </body></noframes>
    </html>
    topframe.html: where the header frame goes
    mainpage.html: where the main area page goes

    Dan
    Last edited by whizard; 02-17-2005 at 06:02 PM. Reason: pb&j got his post in first. GRRR, also rows, not cols.
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #4
    New to the CF scene
    Join Date
    Feb 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    This is the html from my notepad

    </head>


    <frameset rows="30%,70%">
    <frameset src="apply6-1menu.htm" scrolling="yes">
    <frameset src="apply6-1home.htm scrolling="no" name="win-main">
    </frameset>

    <body text="navy" link="navy" vlink="navy" alink="navy">



    <table align="center" rows="2">

    <tr>



    <th valign="top" align="left"><font size="+4" face="bazooka" color="#ff8429">SURF'S

    UP</font>



    </th>

    </tr>

    </table>


    <table align="center" border="0" cols="7" width="55%">

    <tr align="center">

    <td width="1%">|</td>

    <td width="27%"><a href="hnbch.htm" target="win-main2">Huntington Beach</a></td>

    <td width="1%">|</td>

    <td width="17%"><a href="maui.htm" target="win-main2">Maui</a></td>

    <td width="1%">|</td>

    <td width="27%"><a href="ftlaud.htm" target="win-main2">Ft. Lauderdale</a></td>

    <td width="1%">|</td>

    </tr>

    </table>



    </html>


    <body bgcolor="#FFE7C6">



    <center><p><b><font size=+2>Welcome to the Surf's Up Home Page</font></b></p></center>



    <p>Surf's Up is the country's leading surf shop, providing the best boards, gear, and

    accessories for three of America's best surfing spots. Recent sales have soared beyond all

    of management's wildest expectations. Our three surf stores have shot the waves to record

    highs!</p>



    <p>To find store hours, directions, and other information for any of our three Surf's Up

    locations, click the appropriate link in the menu bar.</p>



    <p><font size="-1"><i><center>Call 1-555-SurfsUp or e-mail us at <a

    href="mailto:surfsup@isp.com">surfsup@isp.com</a>

    for more information.</center></i></font>


    </html>

  • #5
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    Give me a minute or two, and i'll rewrite this correctly and show you whats what with frames..
    Dan
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #6
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    In the zip is the (sort-of) corrected code. I made it do what you want it to do, but the code could still use a lot of cleaning up. note that I removed all your <font> tags and replaced them with <hx> (heading) tags. I also replaced <i> with <em> (emphasis) tags.

    If you would like me to post the code and walk through it line by line, just say so and I will.

    About the frameset, notice that one file, frameset.html is used to control the widths and proportions of the frame and two file are used to fill the two rows, one for each row. Also, there is a CSS (Cascading Style Sheet) file included, which holds the definitions of the h1,h2,h3,p,a, and body tags. This way, any files to which you attach the CSS file, will get these definitions automatically. therefore, you could change the background color, or font size, for the entire site just through one file.


    WAIT, Idiot that I can be, I forgot to include the code! D'OH

    Here it is

    Dan
    Attached Files Attached Files
    Last edited by whizard; 02-17-2005 at 07:08 PM.
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •