Currently, the Content Management System displays the specific data on the client in two ways: XML + XSL or HTML. Take csdn as an example. Currently, both methods exist. For example, in the forum, we use XML + XSL, and in the document center we use shtml.
Based on my experiences. XML + XSL has the advantages of separating the data layer from the presentation. XML definition data, XSL definition display. The obvious disadvantage is: 1. Some users may encounter problems when parsing XML + XSL on the client after some XML editors are installed. What users see directly is XML.CodeFrom time to time, some people complain that they cannot view csdn forums. These are the reasons. (This problem is hard to overcome) 2. The XML + XSL complex logic operations are relatively poor. Some complex logic operations occupy a large amount of client resources. For example, the support for UBB is implemented on the basis of the current csdn forum. It is very complicated. If the UBB presentation operation is performed by the client, it cannot be tolerated by anyone. 3. Google does not support searching XML files.
The advantage of using HTML is very simple, and the user is what needs to be presented. The disadvantage is that it is complicated to extract valid data.
Today, when talking to the "wind child" about content and how news systems are presented, I suddenly remembered that we can use the advantages of XML + XSL and HTML at the same time. The specific method is to convert some complex logic operations into server segments, convert these into HTML code, and save the converted content to XML data. <! [CDATA []> section. The XML + XSL method is presented to the user, but this method does not involve complex logic operations on the client. There is not much pressure on user-side parsing, and some complicated functions can be implemented in this way. For example, you can support complex functions such as ubb on the csdn forum.
In the past, I have been opposed to supporting UBB in csdn forums. One important reason is that it puts pressure on customer segments. Now we can solve this problem through the XML + XSL solution integrated into HTML mentioned above. The next-generation csdn forum can do this. But another reason is that it is necessary for technical exchange BBS to be so fancy ?? Especially when many people add Large fonts and special images to their signatures, will there be more problems ??
The XML method in HTML is the data island method. For example, you can refer to the monopoly forum. That is a representative way to apply data islands. When you open a csdn forum, the tree on the left will automatically synchronize the data that needs to be synchronized to that node.
In addition, the shtml method supports include HTML. You can use include in shtml to include some HTM files.
Baidu can find the XML post of the csdn Forum:
Http://www.baidu.com/baidu? Lm = 0 & Si = & Rn = 10 & Ie = gb2312 & Ct = 0 & word = Site % 3 aexpert % 2 ecsdn % 2 enet + % BD % af % EA % C9 & CL = 2