Closed Bug 267074 Opened 20 years ago Closed 20 years ago

width of table set to 100% instead of 90% when Javascript writes drop-down menu form into document that uses height in a table

Categories

(Core :: Layout: Tables, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: AZurcher, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.7) Gecko/20040803 Firefox/0.9.3
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.7) Gecko/20040803 Firefox/0.9.3

http://chanteur.net/biblio/bug.htm is a simplified version of all pages about
one book at http://chanteur.net/biblio/

The whole page is inside a table that uses "height=100%" - which is probably bad
but usually works in Firefox as well as MSIE.

Inside the 2 TR of this table are other tables, some 90% wide, some 100% wide.

Firefox displays certain tables as 100% instead of 90%.

This behaviour is modified when the 2 SCRIPT tags that write the 2 drop-dosn
menus into the document are suppressed :

- if both are suppressed, the problem disappears;
- if the 2nd one only is suppressed, the first 90% wide table is also displayed
as 100%, like the 2nd 90% wide table;
- if the content of the Javascript document.write is directly inserted into the
page, the page is displayed correctly.

NB :
- if "height=100%" is suppressed, the tables are displayed with their good widths;
- if the 2nd TR of the main table is suppressed, the tables are also displayed
with their good widths.


Reproducible: Always
Steps to Reproduce:
Just go to http://chanteur.net/biblio/bug.htm
Actual Results:  
The first 90% wide table is displayed correctly.
The second 90% wide table is displayed as 100%.





Expected Results:  
Both 90% wide tables should be displayed as 90% wide.

Here is the content of naviMenu.js :

document.write('<FORM name="formNavig"><SELECT name="page"
onChange="allerA(document.formNavig.page.options[document.formNavig.page.selectedIndex].value)">');
if(navigator.appName=="Netscape"&&navigator.appVersion.substring(0,1)=="4"){document.write('<OPTION>')};
document.write('<OPTION value="-" style="background-color:#FFFF00">L\'Atelier du
Chanteur</OPTION><OPTION value="index.htm">• Page d\'Accueil</OPTION><OPTION
value="rechSite.htm">• Chercher sur le Site</OPTION><OPTION value="-"
style="background-color:#FFFF66">COMPRENDRE</OPTION><OPTION
value="articles/index.htm">• Articles</OPTION><OPTION value="glossair.htm">• 
Glossaire</OPTION><OPTION value="contribu/index.htm">•
Contributions</OPTION><OPTION value="-"
style="background-color:#FFFF66">PRATIQUER</OPTION><OPTION
value="exosPhy/index.htm">• Exercices Physiques</OPTION><OPTION
value="exosVoc/index.htm">• Exercices Vocaux</OPTION><OPTION
value="cours/index.htm">• Cours de Chant</OPTION><OPTION
value="stages/index.htm">• Stages de Chant</OPTION><OPTION
value="profs/index.htm">• Annuaire Professeurs</OPTION><OPTION value="-"
style="background-color:#FFFF66">&Eacute;CHANGER</OPTION><OPTION
value="liste-chant/index.htm">• Liste Chant</OPTION><OPTION
value="chat/index.htm">• Chat Chant</OPTION><OPTION value="pa/index.shtml">•
Petites Annonces</OPTION><OPTION value="-"
style="background-color:#FFFF66">APPROFONDIR</OPTION><OPTION
value="biblio/index.htm">• Bibliographie</OPTION><OPTION value="liens.htm">•
Liens</OPTION><OPTION value="recherch.htm">• Recherche Internet</OPTION><OPTION
value="-" style="background-color:#FFFF66">CHANTER</OPTION><OPTION
value="vaccai/index.htm">• Vaccai</OPTION><OPTION value="airs/index.htm">•
Airs</OPTION><OPTION value="-"
style="background-color:#FFFF66">&Eacute;COUTER</OPTION><OPTION
value="spectacles/index.htm">• Spectacles</OPTION><OPTION
value="jeunesChanteurs/index.htm">• Jeunes Chanteurs</OPTION><OPTION value="-"
style="background-color:#FFFF66">ADH&Eacute;RER</OPTION><OPTION
value="adhesion.htm">• Association</OPTION><OPTION value="annuaire.htm">•
Annuaire Membres</OPTION><OPTION value="-" style="background-color:#FFFF66">NOUS
CONTACTER</OPTION><OPTION value="question.htm">• Questionnaire</OPTION><OPTION
value="courrier.htm">• Nous &Eacute;crire</OPTION></SELECT></FORM>')

and the one of naviBiblioMenu.js :

document.write('<FORM name="formNaviBiblio"><SELECT name="pageBiblio"
onChange="allerABiblio(document.formNaviBiblio.pageBiblio.options[document.formNaviBiblio.pageBiblio.selectedIndex].value)">');
if(navigator.appName=="Netscape"&&navigator.appVersion.substring(0,1)=="4"){document.write('<OPTION>')};
document.write('<OPTION value="notices.htm"
style="background-color:#FFFF66">Notices</OPTION><OPTION value="notices.htm"
style="color:red">• Liste des ouvrages</OPTION><OPTION value="AFPC1995.htm">•
AFPC 1995</OPTION><OPTION value="AFPC1996.htm">• AFPC 1996</OPTION><OPTION
value="AFPC1997.htm">• AFPC 1997</OPTION><OPTION value="AFPC2001.htm">• AFPC
2001</OPTION><OPTION value="Amy.htm">• Amy de la Bret&egrave;que</OPTION><OPTION
value="Andreossy.htm">• Andr&eacute;ossy</OPTION><OPTION value="Babini.htm">•
Babini</OPTION><OPTION value="Barthelemy.htm">•
Barth&eacute;l&eacute;my</OPTION><OPTION value="Bernac.htm">•
Bernac</OPTION><OPTION value="Blivet.htm">• Blivet</OPTION><OPTION
value="Bonnardot.htm">• Bonnardot &amp; al.</OPTION><OPTION
value="Bourlet.htm">• Bourlet</OPTION><OPTION value="Callas.htm">•
Callas</OPTION><OPTION value="CarusoTetrazzini.htm">• Caruso &amp;
Tetrazzini</OPTION><OPTION value="Cheng.htm">• Chun-Tao Cheng</OPTION><OPTION
value="Coffin1980.htm">• Coffin 1980</OPTION><OPTION
value="colloqueLyon2001.htm">• colloque Lyon 2001</OPTION><OPTION
value="Cornut1983.htm">• Cornut 1983</OPTION><OPTION value="Cross.htm">•
Cross</OPTION><OPTION value="Dinville.htm">• Dinville</OPTION><OPTION
value="Doscher.htm">• Doscher</OPTION><OPTION value="Fernandez-Lavie.htm">•
Fernandez-Lavie</OPTION><OPTION value="Fischer-Dieskau.htm">•
Fischer-Dieskau</OPTION><OPTION value="Fouche.htm">•
Fouch&eacute;</OPTION><OPTION value="Fournier.htm">• Fournier</OPTION><OPTION
value="Garcia.htm">• Garcia</OPTION><OPTION value="Gourret.htm">•
Gourret</OPTION><OPTION value="GourretLabayle.htm">• Gourret &amp;
Labayle</OPTION><OPTION value="Hahn.htm">• Hahn</OPTION><OPTION
value="Hanhart-Nerini.htm">• Hanhart-N&eacute;rini</OPTION><OPTION
value="Heuillet-Martin.htm">• Heuillet-Martin</OPTION><OPTION
value="Hines.htm">• Hines</OPTION><OPTION value="Husson.htm">•
Husson</OPTION><OPTION value="Kagen.htm">• Kagen</OPTION><OPTION
value="Kobbe.htm">• Kobb&eacute;</OPTION><OPTION value="Ladefoged.htm">•
Ladefoged</OPTION><OPTION value="LaMadelaine.htm">• La Madelaine
(de)</OPTION><OPTION value="Lamperti.htm">• Lamperti</OPTION><OPTION
value="Lehmann.htm">• Lehmann (Lilli)</OPTION><OPTION value="Lohmann.htm">•
Lohmann</OPTION><OPTION value="Maet.htm">• Maet (de)</OPTION><OPTION
value="Mancini.htm">• Mancini</OPTION><OPTION value="Fayard.htm">• Mancini &amp;
Rouveroux</OPTION><OPTION value="Mansion.htm">• Mansion</OPTION><OPTION
value="Marchesi.htm">• Marchesi</OPTION><OPTION value="Massell.htm">•
Massell</OPTION><OPTION value="Miller1986.htm">• Miller 1986</OPTION><OPTION
value="Miller1993.htm">• Miller 1993</OPTION><OPTION value="Miller1996.htm">•
Miller 1996</OPTION><OPTION value="Miller2000.htm">• Miller 2000</OPTION><OPTION
value="Ott.htm">• Ott</OPTION><OPTION value="Panzera.htm">•
Panz&eacute;ra</OPTION><OPTION value="Poulenc.htm">• Poulenc</OPTION><OPTION
value="Ragon.htm">• Ragon</OPTION><OPTION value="Ricci.htm">•
Ricci</OPTION><OPTION value="Rondeleux.htm">• Rondeleux</OPTION><OPTION
value="Fayard.htm">• Rosenthal &amp; Warrack</OPTION><OPTION
value="Rouard.htm">• Rouard</OPTION><OPTION value="Stricker.htm">•
Stricker</OPTION><OPTION value="CarusoTetrazzini.htm">• Tetrazzini &amp;
Caruso</OPTION><OPTION value="Tomatis.htm">• Tomatis</OPTION><OPTION
value="Tosi.htm">• Tosi</OPTION><OPTION value="Vennard.htm">•
Vennard</OPTION><OPTION value="Warnant.htm">• Warnant</OPTION><OPTION
value="Wilfart.htm">• Wilfart</OPTION><OPTION value="Wyss.htm">•
Wyss</OPTION><OPTION value="Yaeche.htm">• Ya&egrave;che</OPTION><OPTION
value="ZwickerFeldtkeller.htm">• Zwicker &amp;
Feldtkeller</OPTION></SELECT></FORM>')
I can see the problem with Mozilla1.7, but I can't see the problem anymore, using:
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8a5) Gecko/20041030
Firefox/0.9.1+
It could be this bug has been fixed somewhere in the 1.8 development cycle.
Funnily, this bug does not appear on http://chanteur.net/biblio/Amy.htm

This page contains a long OL
If this OL is suppressed, the bug reappears!
Due to a change in the drop-down menu to compensate for the bug "default select
changed if page reloaded", the bug does no longer appear on
http://chanteur.net/biblio/bug.htm

It is still visible on :

http://chanteur.net/biblio/AFPC2001.htm

It is clear while this long page loads that the main table is first displayed as
90% wide, but when the page is completely loaded, the width is changed to 100%.

But sometimes, the page stays good...

http://chanteur.net/biblio/Hahn.htm is also usually bad when first loaded, then
sometimes good when reloaded, but sometimes stays bad...!!!
Alain, could you please test a current trunk build to see whether the problem is
still there?  You can get one from
ftp://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/
I get the same result as Martijn in comment 1: I see the bug on http://chanteur.
net/biblio/Hahn.htm with 1.7.3 but it WFM with 1.8a5.
I can still see about the same bug with FireFox 1.0.

On http://chanteur.net/biblio/Hahn.htm , only the top table is 90%, while the
middle tables beginning with HAHN, Du Chant and Beaucoup should alos be 90%.

On http://chanteur.net/biblio/AFPC1995.htm , ALL tables appear at 100%!

On http://chanteur.net/biblio/bug.htm , the bug has reappeared : ALL tables
appear at 100%!
Alain, could you please test a _trunk_ firefox build?  The layout engine in
Firefox 1.0 is the 1.7 branch layout engine. It hasn't received most of the
layout fixes that have happened in the last seven monhts.
Sorry, I am only an end-user, and I could not find any instructions to install
nightly builds! :-(
If you have the latest one, could you check that at least
http://chanteur.net/biblio/bug.htm is displayed with the table widths that are
explained on the page?
http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/ has the
nightly firefox builds...  You're right that there are no instructions.

And yes, in a current nightly build over here every single URI listed in this
bug lays out correctly...

Marking worksforme, but please reopen if the problem is present in a current
nightly or in Mozilla 1.8 or Firefox 1.1 (when those ship).
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.