2013-02-01 168 views
0

大約一個月前,我開始在這家公司工作,我一直在努力清理他們的網站。這真是一團糟。我的老闆使用IE瀏覽器,但我使用Chrome瀏覽器,只是一種跑步和槍戰。 jQuery滑塊下面的標題是:「世界級機械工程師&承包商 - 位於PA中部」位於<td>的最左側,但其他h1沒有。我希望該網站在Chrome中的顯示效果與在IE中的顯示效果相同,但它在Chrome中的顯示方式正是我想要的。在Chrome中,h1向右拉40px,將其縮進。我在想什麼,在這裏?IE兼容性,保證金問題

http://www.enginuity-llc.com/index.htm

回答

2

你有無效的標記。請注意下面代碼片段的第二行是如何將h1作爲子元素的table元素。

<tr> 
    <td height="50" colspan="2" valign="bottom"><table width="100%" border="0" cellspacing="0" cellpadding="0"> 
     <h1 style="margin-left:40px">World-Class Mechanical Engineers & Contractors - in Central PA</h1> 
     <p style="margin-left:50px; margin-right:75px">Enginuity, LLC is a local firm with decades of global experience in the HVAC and Plumbing sectors. Whether you're looking for a custom process design/build, a retrofit to existing HVAC equipment, service     and maintenance, or sustainable energy solutions, Enginuity-LLC is your ultimate one-stop partner. What began in 2002 with four mechanical contracting veterans, has grown into an 85-strong firm that still delivers the best design, service, and       support in the business.</p> 
     <p style="margin-left:50px; margin-right:75px">Enginuity-LLC is more than just your local Energy Star Partner & MSCA Green-Star Recipient; we're your solutions provider for the life of your building. We've worked with large enterprises and small businesses, but regardless of what you need, you'll find a level of professionalism and experience unmatched in the HVAC, Plumbing, and Mechanical Contractor market.</p> 
     <h1 style="margin-left:40px">We Specialize in:</h1> 
      <table style="margin-left:80px"> 
       <tr> 
        <td width="180px"> 
         <ul> 
         <li>HVAC</li> 
         <li>Plumbing</li> 
         <li>Medical Gas Piping</li> 
         <li>Pneumatic</li> 
         <li>Hydraulics</li> 
         <li>Steam</li> 
         <li>Compressed Air</li> 
         <li>Process Piping</li> 
         <li>Refrigeration</li> 
         <li>Utility Piping</li> 
         <li>Ventilation</li> 
         </ul>    
        </td> 
        <td width="220px"> 
         <ul> 
         <li>Centrifugal Chillers</li> 
         <li>Special Environments</li> 
         <li>Specialty Fabrication</li> 
         <li>Backflow Preventers</li> 
         <li>Fire Damper Inspection</li> 
         <li>Sheet Metal/Ductwork</li> 
         <li>New Construction</li> 
         <li>Tenant Fitouts</li> 
         <li>Restoration</li> 
         <li>Turn-Key Design/Build</li> 
         <li>Preventative Maintenance</li> 
         </ul>    
        </td> 
        <td width="220px"> 
         <ul> 
         <li>Energy Retrofits</li> 
         <li>Energy Optimization</li> 
         <li>Computer Rooms</li> 
         <li>Climate Control</li> 
         <li>Radiant Floor Systems</li> 
         <li>Geothermal Systems</li> 
         <li>Energy Audits/Benchmarking</li> 
         <li>Fire Damper Inspection</li> 
         <li>Liebert Certified Data-Aire</li> 
         <li>Electrical Controls</li> 
         <li>DDC</li> 
         </ul>    
        </td> 
       </tr> 
      </table> 
      <br> 
     </td> 
    </tr> 

<td align="left" width="800px"> 

此外,如果在IE(F12)您開放開發工具,你會發現,它在這方面的怪胎(對我來說這顯示了<>的孩子,這是不可能的)

enter image description here

0

您可以使用一個CSS復位,然後風格你自己的空間。

復位樣式表的目的是爲了減少在 之類的默認行高度,頁邊距和標題的字體大小, 等瀏覽器的不一致性。

http://meyerweb.com/eric/tools/css/reset/