Home > Article > Web Front-end > What does span mean in html?
Span in html is a tag used to combine inline elements in the document; the tag does not have a fixed format, and it will only produce visual effects when a style is applied to it. Change; if you don't apply a style to , the text in the element will not be visually different from other text.
The operating environment of this article: Windows7 system, HTML5&&CSS3 version, Dell G3 computer.
is used to combine inline elements in the document.
Tags have no fixed format. It only changes visually when you apply a style to it. If you don't apply styles to , the text in the element will not be visually different from other text.
Tags provide a way to isolate a portion of text or a portion of a document.
Use the element to color a part of the text
Code such as:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title></title> </head> <body> <p>我的母亲有 <span style="color:blue;font-weight:bold">蓝色</span> 的眼睛,我的父亲有 <span style="color:darkolivegreen;font-weight:bold">碧绿色</span> 的眼睛。</p> </body> </html>
Effect:
##For more detailed HTML/css knowledge, please visit the
HTML video tutorial column!
The above is the detailed content of What does span mean in html?. For more information, please follow other related articles on the PHP Chinese website!