2013-11-02 61 views
0

當我嘗試運行這段代碼時,我會在每段後面看到插入了其他段落。如何清除這些段落或爲何看到它?正在創建的附加段落

<html> 
    <style> 
     /* The margin set from - top, right, bottom, left*/ 
     p { 
      margin:.5cm 1cm 1cm 1cm; 
      text-decoration:underline; 
      border-style:solid; 
      border-color:red; 
     } 


    </style> 
    <body> 
     <p>This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph<p> 
     <p>This is the Second paragraph<p> 
     <p>This is the Third paragraph<p> 


    </body> 
</html> 

http://jsfiddle.net/xvF85/

回答

3

您需要關閉您的段落正確

<html> 
    <style> 
     /* The margin set from - top, right, bottom, left*/ 
     p { 
      margin:.5cm 1cm 1cm 1cm; 
      text-decoration:underline; 
      border-style:solid; 
      border-color:red; 
     } 


    </style> 
    <body> 
     <p>This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph,This is the First paragraph</p> 
     <p>This is the Second paragraph</p> 
     <p>This is the Third paragraph</p> 


    </body> 
</html> 

幾乎所有的HTML標籤開始<>和結束< />