Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Table, 100% Width, flush with both margins:

Posted on 2000-03-08
5
Medium Priority
?
166 Views
Last Modified: 2010-04-09
I want a table to go across the top of the browser window, to take up the entire thing.

I already have
<BODY topmargin="0" leftmargin="0" marginheight="0" marginwidth="0">
 and
<table width="100%" border="0" cellspacing="0" cellpadding="0">
(the table has a background image that I want to extend to the sides of the browser.)
The trouble is, 100% doesn't do the trick, it needs to be 101 or 102, but  then there's a risk of  horizontal scrollbar- at 100, it there's a largeish visible gap at the right side

If I can't get this, I might use a background image for the whole page, but that's a last resort
0
Comment
Question by:kisrael
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 2

Accepted Solution

by:
mblase earned 150 total points
ID: 2596664
Netscape always assumes there's a scrollbar on the right side, and leaves room for it. I don't think you can get around this, at least not reliably. (Some creative JS code could do the job, by measuring the inside dimensions of the browser window, but the width of the scrollbar would vary from system to system.)

Do you *know* that the page will never require a vertical scrollbar? If so, then I can look up the JS solution for you. If not, I'd let it go with the largeish visible gap for the few cases when it occurs.
0
 

Expert Comment

by:morbiusx
ID: 2598965
insted of using %'s try to use pixels.
0
 

Author Comment

by:kisrael
ID: 2599134
Well, the idea is they want it stretched fully accross with no gaps, but they don't control how wide the screen is.
0
 

Expert Comment

by:morbiusx
ID: 2600024
the best you will get it to fit is set margins at 0 make the table with no border, then strech either 100% or how ever many pixels
0
 

Author Comment

by:kisrael
ID: 2601607
Ehh, javascript might get a little futzy. I think we might experiment with the background image idea, or just live with it. Thanks.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question