I want to know if this way of making a table element is a good or not good?

I have a condition, shown in this image:

It is only allow to use very simple HTML TABLE element to solve.

I wonder my this solution is it the best already?


to look the code: http://jsbin.com/exazif/edit#javascript,html


If you must use a <table>, this method is good. However you should not write colspan="250". Colspan is not designed for that. If you do not have to use a <table> you could use floated div's.

To be honest, there is a big debate about what is better: tables or divs. Read more about it here.

This is pretty good tutorial on basic tables.

You should give your td tags ids and then use css instead of the outdated html-attributes.


table {
  border: none;
  width: 800px;
  border-collapse: collapse; /* instead of cellspacing */
td {
  padding: 0;
td#first_first {
  background-color: 'red';
  width: 400px;
td#first_second {
  background-color: 'blue';
  width: 400px;

And in your html

  <td id="first_first">400x200</td>
  <td id="first_second">400x200</td>

Colspan means for how many columns a td cell extends. So in your code it's not used right. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td

Need Your Help

In IIS7.5 what module removes the body of a 400 Bad Request

asp.net http iis-7.5 httpresponse

I have written ASP.NET (4.0) code that sets the Response.StatusCode to 400 if the data posted to the server is in valid.