A preliminary understanding of XHTML + CSS: div + CSS is called incorrectly ......

Source: Internet
Author: User
I have been studying Div + CSS in the last two days. Actually, I have read Article , Div + CSS, which is called incorrectly, should be XHTML + CSS. DIV is just a tag of XHTML.
Besides, I found that many of our artist's ideas are wrong. For example, some time ago, he said that table should not exist in Div, in addition, his tone seems to be to regard table as a very obsolete and shameful label. Today, I am reading a blog about the explosive growth of teeth. His cognition is:

Both table and UL/OL can generate data rows, but the center of gravity of table should be in generating data columns,
The focus of UL/OL should be on generating data.
Therefore, for single-column and multi-row data, the extended trend is to use uL/OL at the generation level.
The tendency of expansion is to use table when generating columns.


Div Structure Not Layout
I saw an article this afternoon, which was written in the following words:

A really amazing expert is the use of Div and table. Why do we say this? Because the birth purpose of Div and table is different,
Table is born to store data. Div is born to construct a page. to display a large amount of data on the page, table is of course the first choice,CodeLittle. Basically, CSS is not defined. If div is used, you must first simulate the table and then fill in the data.
 
Previously, my cognition was wrong. The artist said that DIV layout, in fact, in terms of standards, div layout is also incorrect. It should be a structure.
I suddenly wanted to post the original words of my teeth, because that sentence makes me feel very happy ......

The most common is the news list on the website, especially the news list of each topic on the homepage. The vast majority of news lists are using uL/ol. I think it is a kind of abuse. We should use table. Go to the backgroundProgramThe news list is generated from the database. In the database, a piece of news is composed of many fields, the brief news table on the homepage and the complete news table on the inner page may call the same stored procedure or SQL statement in some cases. The difference is Data Binding. on the home page, I may only bind the title and time. The inner page may be more complete, such as adding clicks and authors. If a news table has more than three columns, you certainly won't use uL/ol. Are there any essential differences between the two columns and the three columns? I know that the two columns can be easily implemented using uL/OL. Do you want to add a span? What about the three columns? You can add class to span. Okay, it's four columns. Do you still say yes? Yes, I admit I can still do it. You're not bothered!
I think, in the future, if a table problem occurs on the page where the artist is entangled in the DIV structure again, I have enough reason to refute him ...... Heheh.
I still have some gains today. For this XHTML + CSS, I am not going to study it in depth. I only need to understand it. In fact, I still want to be a programmer, we still need to put the main focus on the program, but we will continue to understand this ......

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.