473,903 Members | 3,914 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Table inside <div>

I have a style sheet containing the following definitions:

#leftcontent {
position: absolute;
left:20px;
top:60px;
width:180px;
border:1px solid #000;
padding-top: 15px;
}

#centrecontent {
margin-left: 200px;
margin-right: 200px;
border:1px solid #000;
padding-top: 15px;
}

#rightcontent {
position: absolute;
right:20px;
top:60px;
width:180px;
border:1px solid #000;
}

and inside <div id="centreconte nt"> I have <table width=100%>, which I hoped
would produce a table the width of just the centre section. However, in
Internet Explorer the table is the full width of the page, which then goes
off the side of the window since it is already indented about 200 px. In
any other browser I have tried the table width is correct. Can someone
please tell me what is wrong? Thanks.
Jul 20 '05 #1
3 14411
DU
Joseph Haig wrote:
I have a style sheet containing the following definitions:

#leftcontent {
position: absolute;
left:20px;
top:60px;
width:180px;
border:1px solid #000;
padding-top: 15px;
}

#centrecontent {
margin-left: 200px;
margin-right: 200px;
border:1px solid #000;
padding-top: 15px;
}

#rightcontent {
position: absolute;
right:20px;
top:60px;
width:180px;
border:1px solid #000;
}

and inside <div id="centreconte nt"> I have <table width=100%>, which I hoped
would produce a table the width of just the centre section. However, in
Internet Explorer the table is the full width of the page, which then goes
off the side of the window since it is already indented about 200 px. In
any other browser I have tried the table width is correct. Can someone
please tell me what is wrong? Thanks.


This sort of problems/questions is always easier to solve/answer by
providing an url.

DU
Jul 20 '05 #2
DU wrote:
Joseph Haig wrote:
I have a style sheet containing the following definitions:

#leftcontent {
position: absolute;
left:20px;
top:60px;
width:180px;
border:1px solid #000;
padding-top: 15px;
}

#centrecontent {
margin-left: 200px;
margin-right: 200px;
border:1px solid #000;
padding-top: 15px;
}

#rightcontent {
position: absolute;
right:20px;
top:60px;
width:180px;
border:1px solid #000;
}

and inside <div id="centreconte nt"> I have <table width=100%>, which I
hoped
would produce a table the width of just the centre section. However, in
Internet Explorer the table is the full width of the page, which then
goes
off the side of the window since it is already indented about 200 px. In
any other browser I have tried the table width is correct. Can someone
please tell me what is wrong? Thanks.


This sort of problems/questions is always easier to solve/answer by
providing an url.


It isn't public yet but I have put something that should illustrate it here:

<http://www.maths.man.a c.uk/~jhaig/tmp/page.php>

The style sheet is:

<http://www.maths.man.a c.uk/~jhaig/tmp/layout.css>
Jul 20 '05 #3
DU
Joseph Haig wrote:
DU wrote:

Joseph Haig wrote:

I have a style sheet containing the following definitions:

#leftconte nt {
position: absolute;
left:20px;
top:60px;
width:180px;
border:1px solid #000;
padding-top: 15px;
}

#centreconte nt {
margin-left: 200px;
margin-right: 200px;
border:1px solid #000;
padding-top: 15px;
}

#rightconten t {
position: absolute;
right:20px;
top:60px;
width:180px;
border:1px solid #000;
}

and inside <div id="centreconte nt"> I have <table width=100%>, which I
hoped
would produce a table the width of just the centre section. However, in
Internet Explorer the table is the full width of the page, which then
goes
off the side of the window since it is already indented about 200 px. In
any other browser I have tried the table width is correct. Can someone
please tell me what is wrong? Thanks.


This sort of problems/questions is always easier to solve/answer by
providing an url.

It isn't public yet but I have put something that should illustrate it here:

<http://www.maths.man.a c.uk/~jhaig/tmp/page.php>

The style sheet is:

<http://www.maths.man.a c.uk/~jhaig/tmp/layout.css>

Just validate your HTML code and add a suitable doctype decl. (with a
full url; I recommend strict definition) and the table will be rendered
accordingly in MSIE 6.

DU
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
24004
by: F. Da Costa | last post by:
Following is a snippet of html in which I hide a whole table and try to hide a single row. Here is my question (plz don't chew my head off if its css related instead): Why does the divTable <div> Hide/Show work but not the divRow version? What I'm trying to do here is simultaneously hide 1 or more rows (possibly with nested divs as well). This would allow for an elegant an well performing base for an html base treetable (but I guess...
61
24549
by: Toby Austin | last post by:
I'm trying to replace <table>s with <div>s as much as possible. However, I can't figure out how to do the following… <table> <tr> <td valign="top" width="100%">some data that will 'stretch'</td> <td valign="top" width="300">some data that won't 'stetch'</td> </tr> </table>
7
17007
by: Herbman | last post by:
Hi, I'm trying to position a <tr> ("row") element with CSS. The table itself is positioned with <div> tags. The problem is when I use <div> tags to position the rows within the table nothing happens. In the following example, I want to position two table rows relative to the table itself. Can anyone tell me what I am doing wrong? Please provide sample code.
8
5171
by: slim | last post by:
hi again all, i am still working on the website as mentioned in earlier threads and have hit another snag... http://awash.demon.co.uk/index.php http://awash.demon.co.uk/vd.css the php is pulling a name and placing it under the thumbnail (the text is
2
7584
by: listaction | last post by:
Hi Folks, can you help me by explaining how the code below can be translated using <div> and achieve the same effect? Thanks, LA <html> <body> <table bgcolor="#000000" width="100%" cellspacing="1">
9
3154
by: Julia Briggs | last post by:
How do I construct a <iframe> or equivalent for FireFox/NS browsers, inside a screen centered <div> tag? Can it be done?
5
39017
by: chakradhari.ashish | last post by:
Does anybody know how can I load an html page inside a <div</div> where the content gets update on the onclick even of anchor <a href=> </a>? I googled around and followed some links pointing me that it is possible to use javascript combined with CSS for doing this? Any ideas? Chakra
5
5272
nathj
by: nathj | last post by:
Hi All, I'm working on a new site that has a two column layout underneath a title bar. If you check out: http://www.christianleadership.org.uk/scratch/mainpage.php using IE or Opera you will see what I am after as these browsers work fine. However, in FF the results are slightly different - take a look and you'll see that the <p>, within <div class="mainContent"> has shot way over to the right. I've been working on this for 2days now...
0
9999
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9847
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
10983
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10500
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
5894
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
6088
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4308
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3324
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.