In CSS how do you change font size of h1 and h2

后端 未结 3 1856
旧时难觅i
旧时难觅i 2020-12-31 00:15

In a word press twenty eleven theme. I want to change the size of headings When I wrap my headings around h1 and h2 tags as follows

My h1 heading

相关标签:
3条回答
  • 2020-12-31 00:24
     h1 { font-size: 150%; }
     h2 { font-size: 120%; }
    

    Tune as needed.

    0 讨论(0)
  • 2020-12-31 00:26
    h1 {
      font-weight: bold;
      color: #fff;
      font-size: 32px;
    }
    
    h2 {
      font-weight: bold;
      color: #fff;
      font-size: 24px;
    }
    

    Note that after color you can use a word (e.g. white), a hex code (e.g. #fff) or RGB (e.g. rgb(255,255,255)) or RGBA (e.g. rgba(255,255,255,0.3)).

    0 讨论(0)
  • 2020-12-31 00:29

    What have you tried? This should work.

    h1 { font-size: 20pt; }
    h2 { font-size: 16pt; }
    
    0 讨论(0)
提交回复
热议问题