Bug Tracker

Opened 10 years ago

Closed 10 years ago

#7875 closed bug (invalid)

table weirdness

Reported by: anonymous Owned by:
Priority: undecided Milestone: 1.6
Component: unfiled Version: 1.4.4
Keywords: Cc:
Blocked by: Blocking:


Compare these:

http://www.jsfiddle.net/matteosistisette/KwcKe/ http://www.jsfiddle.net/matteosistisette/3mnpu/ http://www.jsfiddle.net/matteosistisette/E3MBA/

(CAREFUL with the last one: it will generate 75 alerts)

They all do the same: populate 3 initially empty tables with 25 cells each (5 rows by 5 columns) with random background color each cell. The second one has a visible border on cells, which the first one doesn't have; the third one pops up an alert() for each cell it creates.

Other than that, they are identical.

Expected: All should look the same: the three tables should have many cells with different background colors.

Observed: The second and third work as expected. The first one shows each table filled with one homogeneous color (i.e. only 1 color per table). I can't tell whether it is not generating the cells or if it is assigning the same color to all cells; neither behavior makes sense.

The ONLY differences in code are the presence of border in the second one (in CSS), and the alert() in the third one. Neither explains that in one case the cells are not created (or are created all with the same color, can't tell) while in the other cases they are as expected.

Change History (3)

comment:1 Changed 10 years ago by matteosistisette@…

Hi, I tried to file this bug report with my email address which is registered, but it kept being rejected as spam.

Then I filed it as anonymous and it was accepted.

How do I report bugs in the bugtracker?

comment:2 Changed 10 years ago by anonymous

It seems to be a bug in the browser (present with different variants in various browsers) since I can reproduce it with a static table and no scripting at all.

If all the cells are empty and have no "width" and "height" property, AND they have no border, then the LAST cell seems to fill the whole table; while, if the cells do have border, then they get all equal widths and heights - this difference depending on whether they have or not a border doesn't make any sense, let alone it is not specified in the CSS standard.

Even if there was a reasonable explanation for a different behavior between with or without borders, there is still the difference between the case where you create the cells (all without border) with scripting without alerts and the case where you pop up an alert before creating each cell (without border in both cases and with no other difference). That is 100% nonsense.

But this all seems to be a bug of the browser, no jQuery involved.

comment:3 Changed 10 years ago by danheberden

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.