Progress bar in HTML/CSS

前端 未结 4 727
孤独总比滥情好
孤独总比滥情好 2021-01-06 04:08
 dd { 
    /*position: relative; /* IE is dumb */
    display: block;                 
    float: left;     
    width: 500px; 
    height: 16px; 
    margin: 0 0 2p         


        
4条回答
  •  北荒
    北荒 (楼主)
    2021-01-06 04:59

    Are you looking for something like this?

    CSS:

    div.dd { 
       /*position: relative; /* IE is dumb */
        display: block;                 
        float: left;     
        width: 500px; 
        height: 16px; 
        margin: 0 0 2px; 
        background: #fff; 
    }
    
    div.dd div.blue { 
        /*position: relative; */
        background: #00f; 
        height: 16px; 
        width: 75%; 
        text-align:right; 
        display:block;
        float: left;
    }
    div.dd div.red { 
        /*position: relative; */
        background: #f00; 
        height: 16px; 
        width: 75%; 
        text-align:right; 
        display:block;
        float: left;
    }
    

    HTML:

    I'm not sure why you're using the dd tag (for me, this tag causes the divs to render beneath the dd tag, rather than inside).

提交回复
热议问题