" tag in HTML to define the list items; finally use the "list-style" attribute in css to define the list style."/> " tag in HTML to define the list items; finally use the "list-style" attribute in css to define the list style.">

Home  >  Article  >  Web Front-end  >  How to define item list css

How to define item list css

藏色散人
藏色散人Original
2020-12-18 11:08:212741browse

How to define a list of items in css: first create an HTML sample file; then use the "

  • " tag in HTML to define the list items; finally use the "list-style" attribute in css to define the list style That’s it.
  • How to define item list css

    The operating environment of this tutorial: Windows7 system, HTML5&&CSS3 version. This method is suitable for all brands of computers.

    Recommended: "css Video Tutorial"

    In HTML, you can use the

  • tag to define list items, and then use the list-style attribute in css to define the list Style, the shorthand list-style attribute sets all list properties in one declaration.

    You can set the following properties in order:

    • list-style-type

    • list-style-image

    • list-style-position

    Example:

    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8"> 
    <style>
    ul 
    {
    list-style:disc;
    }
    </style>
    </head>
    <body>
    <ul>
    <li>Coffee</li>
    <li>Tea</li>
    <li>Coca Cola</li>
    </ul>
    </body>
    </html>

    The effect is as follows:

    How to define item list css

  • The above is the detailed content of How to define item list css. For more information, please follow other related articles on the PHP Chinese website!

    Statement:
    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