1 | <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script> |
---|
2 | <script> |
---|
3 | $(document).ready(function() { |
---|
4 | $('td').each(function() { |
---|
5 | $(this).width(); //when this line is commented - everything seems to be okay on google chrome |
---|
6 | $(this).css('width','100px'); |
---|
7 | }); |
---|
8 | }); |
---|
9 | </script> |
---|
10 | <style> |
---|
11 | th,td {width: 100px; background: yellow;} |
---|
12 | .hidden {display: none;} |
---|
13 | </style> |
---|
14 | <table> |
---|
15 | <thead><tr><th>1</th><th class="hidden">2</th><th>3</th></thead> |
---|
16 | <tbody><tr><td>4</td><td class="hidden">5</td><td>6</td></tbody> |
---|
17 | <tfoot><tr><td>7</td><td class="hidden">8</td><td>9</td></tfoot> |
---|
18 | </table> |
---|