2017-09-18 4 views
1

複数の列を持つHTML <article>があります。最初の列は、常に他の行より1/2~1行低いです。私は見出しを取り除くことを試みました、そしてそれ以外のものはそれを分離しようとしましたが、私は明らかに何かが欠けています。HTML文書内で不均一な列の先頭

<article id="Safety" style="padding-bottom: 40px;padding-top: 20px;padding-right:30px; padding-left: 50px;"> 
 
    <h3>Safety First: Prescription Safety Glasses</h3> 
 
    <div style="column-count: 2; column-gap: 40px; padding-bottom: 20px; padding-right: 80px; "> 
 
    <a href="https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx" target="_blank"><img src="glasses.jpg" style="max-width: 100%; display: block; float: right; padding-left: 40px;"></a> 
 
    <p>Some of my fellow eyeglass wearers may not be aware that Comcast will pay for you to have your prescription safety glasses fully covered! I recently became aware of this information and wanted to share it with all of you. Per our ComcastNow website, 
 
     in the Vision Benefits SPD: Davis Vision will cover 100% of the cost, VSP- Safety Vision Glasses (Employee only) Coverage 100% after $20 copay; $75 Frame allowance. This helps us all, with the struggle of trying to wear two sets of glasses in order 
 
     to see and be OSHA compliant while working in the field. More information can be found at <a href="https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx">https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx</a> regarding 
 
     this great benefit. </p> 
 
    </div> 
 
    <a href="#contents" class="links">Back to Table of Contents</a> 
 
</article>

+0

これでうまくいきませんでした。あなたは私のHTMLとCSSを見ることができるように投稿する方法を学ばなければならないように見えます。 – sunspore

答えて

1

あなたは段落タグを削除するか、またはあなたの段落要素に0の余白を追加

<article id="Safety" style="padding-bottom: 40px;padding-top: 20px;padding-right:30px; padding-left: 50px;"> 
 
    <h3>Safety First: Prescription Safety Glasses</h3> 
 
    <div style="column-count: 2; column-gap: 40px; padding-bottom: 20px; padding-right: 80px; "> 
 
    <a href="https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx" target="_blank"><img src="glasses.jpg" style="max-width: 100%; display: block; float: right; padding-left: 40px;"></a> 
 
    <p style="margin-top:0">Some of my fellow eyeglass wearers may not be aware that Comcast will pay for you to have your prescription safety glasses fully covered! I recently became aware of this information and wanted to share it with all of you. Per our ComcastNow website, 
 
     in the Vision Benefits SPD: Davis Vision will cover 100% of the cost, VSP- Safety Vision Glasses (Employee only) Coverage 100% after $20 copay; $75 Frame allowance. This helps us all, with the struggle of trying to wear two sets of glasses in order 
 
     to see and be OSHA compliant while working in the field. More information can be found at <a href="https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx">https://my-benefits.ehr.com/US2/EN/myHealth/Vision/Pages/default.aspx</a> regarding 
 
     this great benefit. </p> 
 
    </div> 
 
    <a href="#contents" class="links">Back to Table of Contents</a> 
 
</article>

+0

ありがとうございました!魅力のように働いた。 – sunspore

+0

私の答えの左側にあるチェックマークを押して解決してください – abney317

0

それにmargin-top:0を追加します。

p { margin: 0} 
関連する問題