Table of Contents
Methods to add underline under text in HTML pages
Home Web Front-end HTML Tutorial How to add underline under text

How to add underline under text

Apr 03, 2019 pm 05:03 PM
css html

How to underline a word: First use word software to open a document with text; then select the text that needs to be underlined; finally click the [u] icon in the top menu bar or use the shortcut key [ ctrl u] to add an underline.

How to add underline under text

Methods to add underline under text in HTML pages

The methods to underline text are: use directly The tag in the html tag can achieve the underline effect, and you can also use the underline in the text-decoration attribute in the CSS style to achieve the effect

[Recommended course: HTML tutorialCSS tutorial

Use html underline tag

Add to the text that needs to be underlined in the html tag to achieve the underline style

Example:

<body>
	<p>无下划线:PHP中文网</p>
	<p>有下划线:<u>PHP中文网</u></p>
</body>
Copy after login

Rendering:

How to add underline under text

##CSS style to implement underline style

The underline effect can be achieved through the

text-decoration:underline attribute in the CSS style

<body>
	<p>无下划线:PHP中文网</p>
	<p style="text-decoration: underline;">有下划线:PHP中文网</p>
</body>
Copy after login

Rendering:

How to add underline under text

How to add underline under text in word document

Method 1:

①We still create a text through word2013 A document with text, as shown in the figure.

How to add underline under text

② Then select the text content we intend to add underline, and then click "Font" - "Underline" in the format bar. Let's take the entire document as an example, as shown below. We select all the text content

How to add underline under text

③ Then click the underline icon under the font, and then we see that there is an underline under all the text

How to add underline under text

How to add underline under text

Method 2: Use shortcut keys to add underline

How to add underline under text

This method It is only suitable for adding in the blank space of the document. Position the cursor at the position where you want to add an underline, and then press and hold the "SHIFT" and "-" keys at the same time to underline. We can press it as long as we need. We are currently testing it. It can be applied to any input method...

Summary: The above is the entire content of this article, I hope it will be helpful to everyone

The above is the detailed content of How to add underline under text. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
1 months ago By 尊渡假赌尊渡假赌尊渡假赌
Two Point Museum: All Exhibits And Where To Find Them
1 months ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

HTML Table Layout HTML Table Layout Sep 04, 2024 pm 04:54 PM

Guide to HTML Table Layout. Here we discuss the Values of HTML Table Layout along with the examples and outputs n detail.

How do you parse and process HTML/XML in PHP? How do you parse and process HTML/XML in PHP? Feb 07, 2025 am 11:57 AM

This tutorial demonstrates how to efficiently process XML documents using PHP. XML (eXtensible Markup Language) is a versatile text-based markup language designed for both human readability and machine parsing. It's commonly used for data storage an

HTML Input Placeholder HTML Input Placeholder Sep 04, 2024 pm 04:54 PM

Guide to HTML Input Placeholder. Here we discuss the Examples of HTML Input Placeholder along with the codes and outputs.

HTML5 Interview Questions HTML5 Interview Questions Sep 04, 2024 pm 04:55 PM

HTML5 Interview Questions 1. What are HTML5 multimedia elements 2. What is canvas element 3. What is geolocation API 4. What are Web Workers

Jsoup Example Jsoup Example Sep 04, 2024 pm 04:55 PM

Guide to Jsoup Example. Here we discuss the definition, overview, examples with code implementation & examples respectively.

How to implement the custom table function of clicking to add data in dcat admin? How to implement the custom table function of clicking to add data in dcat admin? Apr 01, 2025 am 07:09 AM

How to implement the table function of custom click to add data in dcatadmin (laravel-admin) When using dcat...

HTML font HTML font Sep 04, 2024 pm 04:53 PM

This is a guide to HTML Schriftart. Here we discuss the intrduction to Html Schriftart with appropriate syntax and respective examples.

HTML special characters HTML special characters Sep 04, 2024 pm 04:55 PM

Guide to HTML Sonderzeichen. Here we discuss the introduction to HTML Sonderzeichen, along with how does it works, and resective examples.

See all articles