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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I get rid of this white space?

Status
Not open for further replies.

whoknows361

Technical User
Sep 22, 2005
228
US
Hello all. I don't post much here in the html section _ but I can't figure this out.

I have a simple html file which is called - which just contains an embedded flash file.
However, there is white space on the top and the left side of the window that is called. Here is my code for the html file:
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"[URL unfurl="true"]http://www.w3.org/TR/html4/loose.dtd">[/URL]
<html>
<head>

<script src="AC_RunActiveContent.js" type="text/javascript"></script>

<title>SES Tennis Center Photo Gallery</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script language="JavaScript" type="text/JavaScript">
<!--



function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->
</script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body>
  <div id="Layer1" width:603px; height:500px; z-index:1;>
    <script type="text/javascript" >
	AC_FL_RunContent('codebase','[URL unfurl="true"]http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0','width','603','height','500','src','galleryone','quality','high','name','galleryone','pluginspage','http://www.macromedia.com/go/getflashplayer','movie','galleryone'[/URL] );
	</script> 

	
	
	
	
	<noscript>
  <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="[URL unfurl="true"]http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0"[/URL] width="603" height="500">
    <param name="movie" value="galleryone.swf" />
    <param name="quality" value="high" />
    <embed src="galleryone.swf" quality="high" pluginspage="[URL unfurl="true"]http://www.macromedia.com/go/getflashplayer"[/URL] type="application/x-shockwave-flash" width="603" height="500"></embed>
  </object>
	</noscript>
  </div>

</body>
</html>

How do I get rid of this unwanted white space?

You can see for yourself if you go to :


and click on View Gallery for the first gallery.

Thanks in advance

BTW - my javascript call from the flash file is:
Code:
on (release) {
getURL ("javascript:NewWindow=window.open('galleryone.htm','newWin','width=603,height=500,left=0,top=0,toolbar=No,location=No,scrollbars=No,status=No,resizable=No,fullscreen=No');  NewWindow.focus();      void(0);");
}

Jonathan
 
I would suggest setting the margin to zero in the body tag like this:
Code:
...
<body style="margin: 0; padding: 0;" topmargin="0" leftmargin="0" marginwidth="0" marginheight="0">
...
As specified on this page
Good luck.

Einstein47
For best results: hand wash in cold, tumble dry low.
For not so good results: drag through puddles, pound on rocks, air dry on tree branch.
[&#91;]Starbase47.com]
 
Although it's worth noting that you don't really need the "leftmargin", "topmargin", "marginwidth", or "marginheight" attributes - the styles alone will do the job in all but old outdated browsers.

Dan



Coedit Limited - Delivering standards compliant, accessible web solutions

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
You might also want to move them from the body into a style section so that you can target the HTML element as well:

Code:
<style type="text/css">
html, body {
   margin: 0px;
   padding: 0px;
}
</style>

Hope this helps,
Dan

Coedit Limited - Delivering standards compliant, accessible web solutions

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top