Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

framespacing = incompliant Please help

Status
Not open for further replies.

CSUKNic

Technical User
Feb 3, 2002
62
0
0
GB
I am trying to write a frame based site (yeah I know...but it's what I do), and I am trying to keep my XHTML compliancy, but I cannot resolve the framespacing=0 issue. I listed this problem here last week and kindly somebody gave me <frameset onload="this.setAttribute('framespacing','0');" cols="190,*">, unfortunately it doesn't work, so I have included the full source code for the page below. Could somebody please help me to get a zero border and zero framespace without losing compliancy.

Nic Brown
TONICweb UK


<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
"<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name="generator" content="TonicWeb"/>
<title>Rookery Manor Bridal</title>
<script language="JavaScript1.2" type="text/javascript">
<!--if (parent.location.href!=window.location.href)parent.location.href=window.location.href;-->
</script>
</head>
<frameset onload="this.setAttribute('framespacing','0');" cols="190,*">
<frameset rows="60,*">
<frame src="rmblogo.html" id="top_left_logo" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="menu_module.html" id="menu_module" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="always_blank.html" id="blank_baseline" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>

<frameset onload="this.setAttribute('framespacing', '0');" rows="10,*,30,70">
<frameset cols="70,30,*">
<frame src="blank_namespace.html" id="blank_frame" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="vertical_tip.html" id="vertical_tip" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="blank_abovebody.html" id="blank_body" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
<frameset onload="this.setAttribute('framespacing', '0');" cols="70,30,*">
<frame src="gown_name_gen.html" id="gown_name" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="vertical_mid.html" id="vertical_mid" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="body_gen.html" id="body" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
<frameset onload="this.setAttribute('framespacing', '0');" cols="70,30,*,10">
<frame src="horizontal_left.html" id="horizontal_left" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="cross.html" id="middle_cross" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="horizontal_mid.html" id="horizontal_right" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="horizontal_tip.html" id="horizontal_tip" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
<frameset cols="70,30,*">
<frame src="blank_left.html" id="blank_left" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="vertical_lower.html" id="vertical_lower" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
<frame src="designer_name_gen.html" id="designer_name" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
<frameset cols="*">
<frame src="always_blankb.html" id="blank_mainbaseline" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
</frameset>
<noframes>

<body>
</body>
 
apologies, the end of the source code got cut off, here it is.


</noframes>
</frameset>

</html>
 
Both the framespacing (IE tag) and border* (Netscape tag) are not part of the HTML 4 or XHTML specs. I have just given up trying to find a standards way of doing this and only let the frameset page fail compliance testing.

* NOTE: IE 6 seems to support the "border" attribute, previous versions may not.

Peter Leing

Peter Leing
Web Programmer
Cenlar FSB
 
Like Peter, I'd just use the [tt]framespacing[/tt] attribute and live with the validation errors. There doesn't appear to be a CSS alternative, whilst the non-standard attributes work fine in current browsers. If that changes in the future, you'll only have one page to fix.

That is one helluva lot of frames for one page though. You're even putting in extra frames that aren't going to be displayed:
Code:
<frameset rows="60,*">
  <frame src="rmblogo.html" id="top_left_logo" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
  <frame src="menu_module.html" id="menu_module" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
  <frame src="always_blank.html" id="blank_baseline" frameborder="0" framespacing="0" border="0" scrolling="no" noresize="noresize"/>
</frameset>
Two frames in the frameset [tt]rows[/tt] attribute, three <frame> elements. Is the third one a spare?

I hope your visitors are patient - since they have to load 18 seperate pages to see your first page in its entirety. My guess is that many won't wait. This may be "what you do", but hey! it's not 1995 any more. Ever heard of tables? ever heard of CSS? ever heard of gettting traffic from search engines? Time to learn some up-to-date page layout techniques!

-- Chris Hunt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top