首页htmlborderPage Widget - 如何向块和内联元素添加边框

Page Widget - 如何向块和内联元素添加边框

我们想知道如何向块和内联元素添加边框。

<!DOCTYPE html>
<html>
<head>
<style type='text/css'>
h1 {
  border-bottom: 1px solid red;
}

span {
  border-bottom: 1px solid blue;
  display: inline-block;
  margin-bottom: -1px;
}
</style>
</head>
<body>
  <h1>
    <span>My Title Test</span>
  </h1>
</body>
</html>