Hello all... i have a really frsutrating problem here...
This is only happening in IE (6 & 7b2), Mozilla and Netscape are both OK.
I have a top-level table with a width of 760px, so it should be 760 minimum
and stretching wider as needed to fit content (such as bound datagrids).
In the top TR/TD, i have a header table which is width of 100%, and has
three TD's. Each contains one image file, with the middle TD being set to
width 100%.
So the td should push the end TDs to as narrow as the images in them, which
works perfectly. The middle TD is giving me a problem though. If it is
empty, then everything behaves as expected, with the whole content being
760px minimum, stretching as needed.
Next i try to add an image to the middle td of the header table. I would
expect the TD to stretch bigger as needed to fit the width of the picture.
Instead it stretches wider to fit the width of the image PLUS an additional
190 pixels of just empty whitespace, which screws up the layout of my page
now.
Anyone seen this before or have an idea how to fix it? I tried putting a
style="float: <value>" on the middle image as sometimes that fixes weird
image layout problems, but it didnt help. I also tried GIFs instead of PNGs
but that was no help either.
Essentially the code looks like this:
<table width="760px">
<tr><td id="tdHeader">
<table width="100%">
<tr><td>
<img src="/images/headerLeft.png" >
</td></td>
<tr><td width="100%">
<img src="/images/headerMiddle.pn g" >
<!-- it renders an extra 190px of width right
here -->
</td></td>
<tr><td>
<img src="/images/headerRight.png " >
</td></td>
</table>
</td></td>
<tr><td id="tdContent"> </td></td>
<tr><td id="tdFooter"> </td></td>
</table> 4 1785
Hi,
Arthur Dent wrote: Hello all... i have a really frsutrating problem here... This is only happening in IE (6 & 7b2), Mozilla and Netscape are both OK.
I have a top-level table with a width of 760px, so it should be 760 minimum and stretching wider as needed to fit content (such as bound datagrids). In the top TR/TD, i have a header table which is width of 100%, and has three TD's. Each contains one image file, with the middle TD being set to width 100%. So the td should push the end TDs to as narrow as the images in them, which works perfectly. The middle TD is giving me a problem though. If it is empty, then everything behaves as expected, with the whole content being 760px minimum, stretching as needed. Next i try to add an image to the middle td of the header table. I would expect the TD to stretch bigger as needed to fit the width of the picture. Instead it stretches wider to fit the width of the image PLUS an additional 190 pixels of just empty whitespace, which screws up the layout of my page now.
Anyone seen this before or have an idea how to fix it? I tried putting a style="float: <value>" on the middle image as sometimes that fixes weird image layout problems, but it didnt help. I also tried GIFs instead of PNGs but that was no help either.
Essentially the code looks like this:
<table width="760px"> <tr><td id="tdHeader"> <table width="100%"> <tr><td> <img src="/images/headerLeft.png" > </td></td> <tr><td width="100%"> <img src="/images/headerMiddle.pn g" > <!-- it renders an extra 190px of width right here --> </td></td> <tr><td> <img src="/images/headerRight.png " > </td></td> </table> </td></td> <tr><td id="tdContent"> </td></td> <tr><td id="tdFooter"> </td></td> </table>
First, your table is invalid. You have a </td> too much and a </tr> too
little.
Then, I noticed strange effects when unnecessary carriage returns were
placed in a table. Try this:
<table width="760px">
<tr>
<td id="tdHeader">
<table width="100%">
<tr>
<td><img src="/images/headerLeft.png" ></td>
</tr>
<tr>
<td width="100%"><i mg src="/images/headerMiddle.pn g"></td>
</tr>
<tr>
<td><img src="/images/headerRight.png "></td>
</tr>
</table>
</td>
</tr>
<tr><td id="tdContent"> </td></tr>
<tr><td id="tdFooter"> </td></tr>
</table>
HTH,
Laurent
Oops, yah, those extra TDs were supposed to be TRs. Typo - i manually typed
that in the msg instead of copy/pasting.
I tried putting all my TD content on one line as in :
<td><img src='/images/someImage.gif'> </td>
but to no avail.... it still keeps the table wider than it needs to be by
the same approx. 190 px.
Thanks for the idea though. :) .
"Laurent Bugnion" <ga*********@bl uewin.ch> wrote in message
news:O9******** ******@TK2MSFTN GP10.phx.gbl... Hi,
Arthur Dent wrote: Hello all... i have a really frsutrating problem here... This is only happening in IE (6 & 7b2), Mozilla and Netscape are both OK.
I have a top-level table with a width of 760px, so it should be 760 minimum and stretching wider as needed to fit content (such as bound datagrids). In the top TR/TD, i have a header table which is width of 100%, and has three TD's. Each contains one image file, with the middle TD being set to width 100%. So the td should push the end TDs to as narrow as the images in them, which works perfectly. The middle TD is giving me a problem though. If it is empty, then everything behaves as expected, with the whole content being 760px minimum, stretching as needed. Next i try to add an image to the middle td of the header table. I would expect the TD to stretch bigger as needed to fit the width of the picture. Instead it stretches wider to fit the width of the image PLUS an additional 190 pixels of just empty whitespace, which screws up the layout of my page now.
Anyone seen this before or have an idea how to fix it? I tried putting a style="float: <value>" on the middle image as sometimes that fixes weird image layout problems, but it didnt help. I also tried GIFs instead of PNGs but that was no help either.
Essentially the code looks like this:
<table width="760px"> <tr><td id="tdHeader"> <table width="100%"> <tr><td> <img src="/images/headerLeft.png" > </td></td> <tr><td width="100%"> <img src="/images/headerMiddle.pn g" > <!-- it renders an extra 190px of width right here --> </td></td> <tr><td> <img src="/images/headerRight.png " > </td></td> </table> </td></td> <tr><td id="tdContent"> </td></td> <tr><td id="tdFooter"> </td></td> </table>
First, your table is invalid. You have a </td> too much and a </tr> too little.
Then, I noticed strange effects when unnecessary carriage returns were placed in a table. Try this:
<table width="760px"> <tr> <td id="tdHeader"> <table width="100%"> <tr> <td><img src="/images/headerLeft.png" ></td> </tr> <tr> <td width="100%"><i mg src="/images/headerMiddle.pn g"></td> </tr> <tr> <td><img src="/images/headerRight.png "></td> </tr> </table> </td> </tr> <tr><td id="tdContent"> </td></tr> <tr><td id="tdFooter"> </td></tr> </table>
HTH, Laurent
Hi Arthur,
Arthur Dent wrote: Oops, yah, those extra TDs were supposed to be TRs. Typo - i manually typed that in the msg instead of copy/pasting.
I tried putting all my TD content on one line as in :
<td><img src='/images/someImage.gif'> </td>
but to no avail.... it still keeps the table wider than it needs to be by the same approx. 190 px. Thanks for the idea though. :) .
Can you email me the HTML/CSS code that displays the problem? If I can
reproduce it, I'll try to solve it.
Greetings,
Laurent
Instead setting the middle TD's width to 100%, try setting the end TDs'
width to 1%, and leave the middle TD's width blank. This is how I
always do it, and it works like a charm in IE.
HTH
Luke This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Andre |
last post by:
Hello,
I was wondering how to do percentage widths for tables. I thought
simply having the width="15%" would do it. I had it so that there is
only one row, and three data cells. Each cell were set to 15%, 70%
and 15%, table width=100%.
It works fine in opera, but not in IE. Can someone please help me?
The website is http://www.oregonsae.org/2004mbw/
|
by: Kim Scarborough |
last post by:
Say I wanted to put a couple lines of asterisks between paragraphs, and have
it stretch the spaces so that it spanned 100% of the text-width, like this:
* * * * * * * *
Is there a way to do this in CSS? I don't want it to line break, just collapse
the spacing between the stars if the window gets narrower.
--
----------------------------------------------------------------------------
|
by: rwmorey |
last post by:
Hi..
I have this code in my page
<table width="100%" cellspacing="0" cellpadding="0" border="0">
<tr><td width="9"><img src="topLeft.gif"></td>
<td>text goes here</td>
<td width="9"><img src="topRight.gif"></td>
</tr>
</table>
|
by: Jeff |
last post by:
I've been trying for days to figure out why the spacing between the
rows on the left-most column of my table is screwy. Take a look here:
http://mypage.iu.edu/~jbeverid/index_new.htm
Right after the graphic link that says "Study Opportunities" the
spacing between the graphics in the column starts to get wider and
wider and I can't figure out how to fix it. I COULD create a seperate
table out of the left column which would probably fix...
|
by: Bernard Dhooghe |
last post by:
Environment: DB2 UDB LUW 8.2
Following problem was submitted.
create table t1 (c1 char(10) not null)
insert into t1 values(default)
This will result in (db2 command line):
| |
by: rsearing |
last post by:
I am new to HTML and will have to beg if this is obvious, but I am trying to design a table that looks like:
********************************
*----A------*------------------------*
************------------------------*
*------------*------------------------*
*------------*------------------------*
*----B------*------------C----------*
*------------*-------------------------*
********************************
|
by: James |
last post by:
I am not sure whether users can access data or insert new data into
tables who belong to a rebalanced table space after new containers are
added? (DB2 version is 8.x) What I know is user can not insert new
data into tables who belong to a rebalanced table space. Is the any
way to avoid this?
Thanks
James
|
by: Grant Kelly |
last post by:
I'm wondering if it's possible within HTML markup (or possibly CSS) to
specify that an HTML table's headers should be placed 'over' the cell
borders rather than 'within' the cells.
For example (requires monospace font):
Default:
+--------------------+
| H1 H2 H3 |
+--------------------+
|
by: Ali Rizwan |
last post by:
Hi all,
I m stretching my form and i want if i stretch its position after stretching must be in middle of screen or i want to stretch centerly.
Thanx
>> ALI <<
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
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,...
| |
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
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...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
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
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
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...
| |