XHTML Tutorial: XHTML Basics for Beginners

XHTML Tutorial: XHTML Basics for Beginners
<br />This site’s original content, please indicate the source 123WORDPRESS.COM when reprinting.
Preface:
Nowadays, we all pay attention to standard website building, and the technologies used in standard website building are mainly XHTML CSS. Now we generally use HTML code, so how can I convert it? And what is the difference between HTML and XHTML? In this tutorial, you will learn the difference between HTML and XHTML, and how to convert HTML to XHTML. After all, XHTML is the direction of development, so I think it is necessary to publish this tutorial on this site. I feel that if you want to use standards it is better to learn HTML first, because it is easier, and then look at this tutorial.
XHTML Introduction:
XHTML is the abbreviation of EXtensible HyperText Markup Language, while HTML is HyperText Markup Language. This is the difference in name. In fact, the standard we are talking about should be XML, so why should we learn XHTML? Because the current HTML code is cumbersome and full of dangers, but the XML usage environment is still immature, an intermediate product, XHTML, was launched, which plays a role in both ends. Some people think that XHTML is an upgraded version of HTML, which is actually correct. My understanding is that XHTML makes HTML a more standardized markup language, making HTML more powerful and reducing the cumbersomeness of the code, especially tables.
XHTML was defined as a standard by the international standards organization W3C (World Wide Web Consortium) on January 26, 2000. It is considered to be the latest version of HTML and will gradually replace HTML. All browsers now support XHTML, which is compatible with HTML 4.0. Some people also think that XHTML is HTML4.01. If you write a standard-compliant site yourself during the learning process, you can pass the W3C validation, and you will get a logo after the validation, usually XHTML1.0 certification and CSS validation. I am not sure how many websites in China have passed both verifications. You can go to http://www.w3.org/ to verify your website. If it meets the two rules, we will give us two pieces of code to add to your web page to show others that you have used standard website building. That's awesome!
Why We Use XHTML
XHTML is a transitional product from HTML to XML and is defined as a standard. XHTML is fully compatible with HTML 4.01 and has XML syntax. Let's take a look at an HTML file containing an error code, as follows:
<html>
<head>
<title>This is bad HTML</title>
<body>
<h1>Bad HTML
</body>
Although it contains error codes, it can still be displayed normally when we browse it in the browser. XML is a markup language, but it requires that any element appearing in a web page should be marked. XML is used to describe the data in a web page, while HTML is used to display the elements in a web page. The various browser technologies we currently use to browse the Internet, including laptops, mobile phones, etc., all require that some of the content being browsed must be correctly marked. If there are incorrect marks, the display may be extremely confusing or even not display properly.
So combining HTML and XML, along with a few other technologies, we get a language that is useful now and will be useful in the future - XHTML.
When everything is standardized in the future, we will have to use XHTML correctly formatted tags so that all browsers can execute them correctly, so it is necessary for us to start learning XHTML now.
Difference between XHTML and HTML:
XHTML is a new technology. Before browsers and other software support it, we should be familiar with it. In order to better learn XHTML, we should be familiar with HTML4.0 before we can download a reference manual to familiarize ourselves with it. In order to make it easier for us to learn XHTML, in other words, we should try our best to write less wrong codes when writing HTML codes, such as: use lowercase characters to write HTML, and add the end of the tag after each tag, such as: <p>123WORDPRESS.COM Welcome you</p> The end must be there, we must maintain this rule.
Previous Page 1 2 3 4 5 6 Next Page Read More

<<:  JavaScript anti-shake and throttling detailed explanation

>>:  404 error occurs when accessing the homepage of tomcat started in Docker mode

Recommend

Detailed introduction to Mysql date query

Query the current date SELECT CURRENT_DATE(); SEL...

mysql 8.0.19 win10 quick installation tutorial

This tutorial shares the installation tutorial of...

Solve the problem of docker pull being reset

This article introduces how to solve the problem ...

Implementation of dynamic rem for mobile layout

Dynamic rem 1. First, let’s introduce the current...

js version to realize calculator function

This article example shares the specific code of ...

JavaScript to achieve simple drag effect

This article shares the specific code of JavaScri...

Basic application methods of javascript embedded and external links

Table of contents Basic application of javascript...

Summary of MySql import and export methods using mysqldump

Export database data: First open cmd and enter th...

Detailed explanation of JSON.parse and JSON.stringify usage

Table of contents JSON.parse JSON.parse Syntax re...

Solution to the failure of loading dynamic library when Linux program is running

Unable to load dynamic library under Linux When t...

Introduction and tips for using the interactive visualization JS library gojs

Table of contents 1. Introduction to gojs 2. Gojs...

Detailed installation tutorial of zabbix 4.04 (based on CentOS 7.6)

1. Preparation before installation: 1.1 Install J...

Detailed explanation of using echarts map in angular

Table of contents Initialization of echart app-ba...

Application of CSS3 animation effects in activity pages

background Before we know it, a busy year is comi...