html基础

2021-03-27 22:29

阅读:648

标签:charset   通过   运行   label   day   you   jpg   src   comm   

遇到的问题:html文件运行时没有调用css中设置的样式

1.HTML文件

DOCTYPE html>
html lang="en">
head>
    meta charset="UTF-8">
    meta name="viewport" content="width=>, initial-scale=1.0">
    title>William‘s htmltitle>
    style>
        /*I am adding some css here to make things look better~~*/
        /* h1{color: aqua;}
        p{
            color: red;
        } */

/*  */
        /* #who{
            color: seagreen;
            widows: 500px;
            height: 500px;
            font-size: 200%;

        }
        .intro{
            color: steelblue;

        } */
    style>
    link rel="stylesheet" href="style.css">


head>
body>
    
    div>
        h1 id="heading">em>This is a heading,yeal!!!em>h1>
        p class="intro">This is a paragram.p>

        h2 id="who">em>Who am I?Who am IWho am IWho am IWho am IWho am IWho am IWho am IWho am I
            Who am IWho am IWho am IWho am IWho am IWho am IWho am IWho am IWho am IWho am I
        em>h2>
        p class="name">I‘m Williamp>
        p class="place"> I am come from earthp>

        span>strong>This is a span,yeah!!!!!!!!!!!strong>span>
        span>This is a another span,span>
        img src="white hat.jpg" alt="There should to be a img">
        a href="https://www.bing.com">Click me to search~~~a>
    div>

    form action="" method="">
        input type="text">This is a text input~
        input type="date">This is a date input~
        input type="radio">This is a radio input~
        input type="checkbox">This is a checkbox~
    form>

    form action="" method="">
        label for "name">Please Enter Your Nameinput type="text" id="name">br>
        label for "age">Plese Enter Your Birthdayinput type="date" id="age">br>
        label for "service1">Service1 input type="radio" id="service1">br>
            label for "service2">Service2 input type="radio" id="service2">br>
                label for "service3">Service3 input type="radio" id="service3">br>
        input type="checkbox">This is a checkbox~br>
        button>I am just a normal buttonbutton>
        button type="submit">I am a very powerfull buttonbutton>
        button type="reset">I am a evil reset buttonbutton>
        button type="button">I am a picture with pic of white hat.jpgbr>
            img src="white hat.jpg" alt="Still a white hat img">
        button>

    form>
body>
html>

2.css文件

    /*I am adding some css here to make things look better~~*/
    /* h1{color: aqua;}
    p{
        color: red;
    } */

/*  */
    #who{
        color: seagreen;
        widows: 500px;
        height: 500px;
        font-size: 200em;

    }
    .intro{
        color: steelblue;

    }

3.学习资源

https://www.w3school.com.cn

https://developer.mozilla.org/zh-CN/

 

html基础

标签:charset   通过   运行   label   day   you   jpg   src   comm   

原文地址:https://www.cnblogs.com/jpr-ok/p/12625348.html


评论


亲,登录后才可以留言!