如何使用 css 对齐边框

How to align a border using css

如何在此代码中右对齐边框?

这是我的 CSS 代码:

p {
  text-align: right;
  color: #757575;
  Background-color: #FFFFFF;
  font-size: 2.4em;
  width: 50px;
}
<p>Home<br>
  <a href="aboutus.html">About</a><br>
  <a href="gallery.html">gallery</a><br>
  <a href="shop.html">club shop</a><br>
  <a href="theteam.html">The Team</a><br>
  <a href="theteam.html">The Team</a><br>
  <a href="mappractice.html">location</a><br>
  <a href="contactus.html">contact us</a><br>
</p>

您可以使用以下任何一项 css class 将您的边框指向任何方向。希望这就是您要实现的目标。

.border-right{ border-right: 1px solid black;}

.border-top{ border-top: 1px 纯黑色;}

. 左边框{ 左边框:1px 纯黑色;}

.border-bottom{ border-bottom: 1px 纯黑色;}