段落标记

时间:2015-07-23 21:02:46

标签: html html5 css3

我对段落标记中的HTML锚标记有一个简单的问题。这是一个Bootstrap模板。

在小型和超小型ViewPorts中查看网页时出现问题。

Here is the Website

每当缩小到较小的视口时,Anchor Tag按钮会移动到容器外部。我需要Anchor保留在容器中,但我不清楚我需要修改什么。

enter image description here

<div class="item">
   <img class="img-responsive rounded-2x img-width-175 hidden-xs" style="float: left; margin-top: 2px;" src="Images/Home/Exterior2.jpg" alt="Exterior Painter">
   <h3 style="background-color: #FF6D00; margin-top: -2px; float: inherit; text-decoration: underline;"><i>Exterior Painting</i></h3>
   <p class="text-justify" style="text-align: left; font-size: 1.07em; background-color: #FF6D00; padding-left: 8px; padding-bottom: 6px; margin-top: -10px; line-height: 1.37em;">
      Whether your Home is new, or perhaps a farmhouse that was built 80 years ago...
      <a href="Interior-Painting" type="button" class="btn-u" style="font-size: 11px; line-height: .8em; float: right; margin-right: 12px; background: #d96006">Exterior Painting Services</a>
   </p>
</div>

1 个答案:

答案 0 :(得分:1)

我在P标签上添加了clearfix:

<p class="text-justify clearfix" style="text-align: left; font-size: 1.07em; background-color: #5AA608; padding-left: 8px; padding-bottom: 6px; margin-top: -10px; line-height: 1.37em;">