清除元素中的子元素html_HTML中的元素简介

清除元素中的子元素html

An element is a fundamental component that is used to develop web pages. Generally an element as two components: a starting tag and a closing tag. The content is added in between the starting and closing tags. The ending tag is the same as the starting the staring tag except that the ending tag precedes with a "/".

元素是用于开发网页的基本组件。 通常, 元素由两个部分组成: 开始标签和结束标签 。 内容添加在开始标记和结束标记之间。 结束标签与起始凝视标签相同,除了结束标签以“ /”开头。

Syntax:

句法:

    <h1 align="right"> A HEADING </h1>

Here,

这里,

  • H1: tag name, starting tag

    H1 :标签名称,起始标签

  • align="right": name and value. It is an attribute

    align =“ right” :名称和值。 这是一个属性

  • A HEADING: Content

    标题 :内容

  • /H1: end tag

    / H1 :结束标签

HTML元素的类型 (Types of the HTML elements)

The elements in the HTML are classified in two types,

HTML中的元素分为两种类型,

1) Container Elements

1)容器元素

These elements have a starting and an ending tag. The content is given in between the tags.

这些元素具有开始和结束标记。 内容在标签之间给出。

Example:

例:

    <b>this element is used for bold text</b>

2) Empty Elements

2)空元素

These elements do not contain an ending tag. They have a starting tag only. These elements are used for performing some specific functions.

这些元素不包含结束标记。 它们仅具有开始标记。 这些元素用于执行某些特定功能。

Exampple:

范例:

    This element is used to give a horizontal rule or say line.
<hr />

The HTML elements can also be used in a nested form.

HTML元素也可以嵌套形式使用。

    <b> <i> to give BOLD and ITALICS letters </i> </b>

With the nested elements one should careful with the closing tags. That means the inner tags should be closed first then the outer tags. Like in the above example, the <i> tag closed before the <b> tag.

对于嵌套元素,应该注意结束标记。 这意味着应该先关闭内部标签,然后再关闭外部标签。 像上面的示例一样, <i>标记在<b>标记之前关闭。

文本级元素 (TEXT-LEVEL ELEMENTS)

It is also known as inline elements, they affect the appearance of the text in a web-page.

也称为内联元素,它们会影响网页中文本的外观。

It is of two types,

它有两种类型,

1) Physical Elements

1)物理元素

It is also known as the character formatting elements, it specifies the display of the text on the webpage. For example: to highlight or to underline the text in the webpage. Some commonly used elements are BOLD (<b>...</b>), ITALICS (<i>...</i>), UNDERLINE (<u>...</u>), SUPERSCRIPT (<sup>...</sup>), SUBSCRIPT (<sub>...</sub>), and STRIKE (<strike>...</strike>).

也称为字符格式元素,它指定文本在网页上的显示。 例如:突出显示或在网页上加下划线。 一些常用元素包括BOLD( <b> ... </ b> ),ITALICS( <i> ... </ i> ),UNDERLINE( <u> ... </ u> ),SUPERSCRIPT( < sup> ... </ sup> ),SUBSCRIPT( <sub> ... </ sub> )和STRIKE( <strike> ... </ strike> )。

2) Logical Elements

2)逻辑元素

It describes the logical or general description of the webpage. These elements are used to define the structural importance of the text. Some commonly used logical elements are SAMPLE, CODE, CITE, STRONG, EMPHASIS, VARIABLE.

它描述了网页的逻辑或一般描述。 这些元素用于定义文本的结构重要性。 一些常用的逻辑元素是SAMPLE,CODE,CITE,STRONG,EMPHASIS,VARIABLE。

块级元素 (BLOCK-LEVEL ELEMENTS)

The block elements are used for defining a block of text in the HTML document. These elements could be nested and used. It gives a structure of a block containing other block elements. Some common examples are HEADING, PARAGRAPH, BREAK, HR AND CENTER.

块元素用于定义HTML文档中的文本块。 这些元素可以嵌套和使用。 它给出了包含其他块元素的块的结构。 一些常见的示例是HEADING,PARAGRAPH,BREAK,HR和CENTER。

HTML的一些元素 (Some Elements of HTML)

<HTML>

<HTML>

This element defines the ones complete HTML document. Also, it is used as the first tag of the HTML document. It is a container element as it has both the starting and closing tag.

该元素定义了完整HTML文档。 此外,它还用作HTML文档的第一个标签。 这是一个容器元素,因为它同时具有开始和结束标签。

    <HTML> ... </HTML>

<BODY>

<身体>

This element defines the body of the document. The element or the content that has to be added to the webpage is given in the HTML body. It has both the starting and the ending tag.

此元素定义文档的主体。 HTML正文中提供了必须添加到网页的元素或内容。 它同时具有开始和结束标记。

    <BODY> ... </BODY>

<HEAD>

<头>

The element is used for the head of the document. This element contains the title of the document, linking to scripts, adding style by style tag, etc.

该元素用于文档的开头。 该元素包含文档的标题,链接到脚本,通过样式标签添加样式等。

    <HEAD>
<TITLE> MY TITLE </TITLE>
<STYLE> . . . </STYLE>
</HEAD>

翻译自: https://www.includehelp.com/html/introduction-to-elements-in-html.aspx

清除元素中的子元素html

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/543971.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

分页 + 模糊查询竟然有坑?

不知道你有没有使用过Mysql的like语句&#xff0c;进行模糊查询&#xff1f;不知道你有没有将查询结果&#xff0c;进行分页处理&#xff1f;模糊查询&#xff0c;加上分页处理&#xff0c;会有意想不到的坑&#xff0c;不信我们继续往下看。我之前提供过一个品牌查询接口&…

导致事务@Transactional失效的5种场景!

作者 | 磊哥来源 | Java面试真题解析&#xff08;ID&#xff1a;aimianshi666&#xff09;转载请联系授权&#xff08;微信ID&#xff1a;GG_Stone&#xff09;一个程序中不可能没有事务&#xff0c;而 Spring 中&#xff0c;事务的实现方式分为两种&#xff1a;编程式事务和声…

操作系统 cpu调度_CPU调度| 操作系统

操作系统 cpu调度调度标准 (Scheduling Criteria) There are many criteria which have been suggested for comparing the CPU scheduling algorithms. The characteristics which are used for comparison and then used to determine the best algorithms, for this some of…

IOS中KVO模式的解析与应用

最近老翁在项目中多处用到了KVO&#xff0c;深感这种模式的好处。现总结如下&#xff1a; 一、概述 KVO,即&#xff1a;Key-Value Observing&#xff0c;它提供一种机制&#xff0c;当指定的对象的属性被修改后&#xff0c;则对象就会接受到通知。简单的说就是每次指定的被观察…

使用 lambda 实现超强的排序功能

我们在系统开发过程中&#xff0c;对数据排序是很常见的场景。一般来说&#xff0c;我们可以采用两种方式&#xff1a;借助存储系统&#xff08;SQL、NoSQL、NewSQL 都支持&#xff09;的排序功能&#xff0c;查询的结果即是排好序的结果查询结果为无序数据&#xff0c;在内存中…

java 的23种设计模式 之单身狗和隔壁老王的故事

2019独角兽企业重金招聘Python工程师标准>>> 觉得代码写的别扭了&#xff0c;回头翻翻java 的23种设计模式。today,额,这么晚了&#xff0c;困了。就弄个最简单的单例模式吧。单例模式&#xff1a;俗称单身狗 package singleton; public class SingleTon { private …

使用python学线性代数_二项式过程| 使用Python的线性代数

使用python学线性代数When we flip a coin, there are two possible outcomes as head or tail. Each outcome has a fixed probability of occurrence. In the case of fair coins, heads and tails each have the same probability of 1/2. In addition, there are cases in …

工作中常见的 6 种设计模式,你用过几种?

前言 哈喽&#xff0c;大家好。平时我们写代码呢&#xff0c;多数情况都是流水线式写代码&#xff0c;基本就可以实现业务逻辑了。如何在写代码中找到乐趣呢&#xff0c;我觉得&#xff0c;最好的方式就是&#xff1a;使用设计模式优化自己的业务代码。今天跟大家聊聊日常工作中…

c#抽象属性_C#中的抽象属性

c#抽象属性C&#xff03;抽象属性 (C# Abstract properties) An abstract may contain some abstract properties. That can be implemented in derived class. Here we use abstract and override keywords. 抽象可能包含一些抽象属性。 可以在派生类中实现 。 在这里&#xf…

这12款idea插件,能让你代码飞起来!

前言基本上每个程序员都会写代码&#xff0c;但写代码的速度不尽相同。为什么有些人&#xff0c;一天只能写几百行代码&#xff1f;而有些人&#xff0c;一天可以写几千行代码&#xff1f;有没有办法&#xff0c;可以提升开发效率&#xff0c;在相同的时间内&#xff0c;写出更…

node js 开发网站_使用Node JS开发网站

node js 开发网站You will have your own fully functional website running on "localhost" after going through this article. 阅读完本文后&#xff0c;您将在“ localhost”上运行自己的功能齐全的网站 。 Basic knowledge of JavaScript and HTML is a prereq…

hdu 1166 敌兵布阵

Problem DescriptionC国的死对头A国这段时间正在进行军事演习&#xff0c;所以C国间谍头子Derek和他手下Tidy又开始忙乎了。A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任务就是要监视这些工兵营地的活动情况。由于采取了某种先进的监测手段&#xff0c;所以每个工兵营地…

Java:LocalDate / LocalDateTime加减时间

在线API参考&#xff1a;LocalTime (Java Platform SE 8 ) 方法介绍 方法1方法1说明plusYears(long years) minusYears(long years) 返回增加/减少了年数的副本plusMonths(long months) minusMonths(long months)返回增加/减少了月数的副本plusWeeks(long weeks) minusWeeks(…

集合 List 分片的 5 种实现

作者 | 磊哥来源 | Java中文社群&#xff08;ID&#xff1a;javacn666&#xff09;转载请联系授权&#xff08;微信ID&#xff1a;GG_Stone&#xff09;前些天在实现 MyBatis 批量插入时遇到了一个问题&#xff0c;当批量插入的数据量比较大时&#xff0c;会导致程序执行报错&a…

消失的死锁

问题描述 如果java层面发生了死锁&#xff0c;当我们使用jstack命令的时候其实是可以将死锁的信息给dump出来的&#xff0c;在dump结果的最后会有类似Found one Java-level deadlock:的关键字&#xff0c;接着会把发生死锁的线程的堆栈及对应的同步锁给打印出来&#xff0c;这次…

ruby 新建对象_Ruby中的面向对象编程

ruby 新建对象Before getting into understanding how Object-oriented programming is implemented in Ruby, let us first understand what Object Oriented means. 在了解如何在Ruby中实现面向对象的编程之前&#xff0c;让我们首先了解面向对象的含义。 Object-oriented p…

使用它给 ​xxl-job 添加任务,太爽了

xxl-job是一款非常优秀的任务调度中间件&#xff0c;轻量级、使用简单、支持分布式等优点&#xff0c;让它广泛应用在我们的项目中&#xff0c;解决了不少定时任务的调度问题。我们都知道&#xff0c;在使用过程中需要先到xxl-job的任务调度中心页面上&#xff0c;配置执行器ex…

dubboSPI机制浅谈

2019独角兽企业重金招聘Python工程师标准>>> &#xfeff;&#xfeff;&#xfeff;本文重点讲述SPI机制&#xff0c;从jdk和dubbo 1、jdk spi机制 2、dubbo spi实现 首先spi是什么&#xff1f; SPI是为某个接口寻找服务实现的机制。为了实现在模块装配的时候能不在…

python 类中静态变量_Python中的类或静态变量

python 类中静态变量Python类/静态变量 (Python Class / Static Variables) Class or Static variables are class-related variables that are shared among all objects but the instance or non-static variable is unique for each object. In Python, there is no need fo…