Home Web Front-end HTML Tutorial Use the border attribute to make small symbols_html/css_WEB-ITnose

Use the border attribute to make small symbols_html/css_WEB-ITnose

Jun 24, 2016 pm 12:05 PM
border use Attributes frame

While studying the past two days, I found a small symbol on the website and thought it was an inserted img, but I couldn’t find the address of the img after searching for it. Finally, I asked my classmates and learned that it was made using the border attribute. The

symbol is as shown on the right:

The css code is as follows:

.fuhao{    position:absolute;    top:12px;    left:12px;    width:0px;    height:0px;    overflow:hidden;    border-width:6px 0px 6px 6px;    border-color:transparent #A92222;    border-style:dashed none dashed solid;}
Copy after login

Here we use an empty div, fuhao, to define it After positioning, make it height and width 0, but the border has width. So there is nothing inside this div, only the border.

Logically speaking, it should look like this:

Then the following statement makes the upper and lower borders transparent, and the right border 0px, and the symbol is obtained.

Actually, I don’t understand it very well, but I think it’s very interesting to use borders to make symbols. Just use it as you see it.

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 Article Tags

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)

How to adjust window border settings on Windows 11: Change color and size How to adjust window border settings on Windows 11: Change color and size Sep 22, 2023 am 11:37 AM

How to adjust window border settings on Windows 11: Change color and size

How to use GitLab for project document management How to use GitLab for project document management Oct 20, 2023 am 10:40 AM

How to use GitLab for project document management

How to get integer literal properties in Python without SyntaxError? How to get integer literal properties in Python without SyntaxError? Aug 20, 2023 pm 07:13 PM

How to get integer literal properties in Python without SyntaxError?

How to make custom borders in Microsoft Word How to make custom borders in Microsoft Word Nov 18, 2023 pm 11:17 PM

How to make custom borders in Microsoft Word

Python's dir() function: View the properties and methods of an object Python's dir() function: View the properties and methods of an object Nov 18, 2023 pm 01:45 PM

Python's dir() function: View the properties and methods of an object

How to rename properties of JSON using Gson in Java? How to rename properties of JSON using Gson in Java? Aug 27, 2023 pm 02:01 PM

How to rename properties of JSON using Gson in Java?

Popular science on how to set excel borders Popular science on how to set excel borders Mar 20, 2024 am 10:30 AM

Popular science on how to set excel borders

What does TikTok recommended video mean? How to use Douyin to recommend videos? What does TikTok recommended video mean? How to use Douyin to recommend videos? Mar 27, 2024 pm 03:01 PM

What does TikTok recommended video mean? How to use Douyin to recommend videos?

See all articles