html - 图像周围有白色边框

标签 html css

晚上好。 我上传了一个测试索引页,上面的图片有悬停灰色背景,底部的社交图标有灰色背景,它们都有白色边框。

比较迷茫。

http://www.garyhornephotography.com/str/index.html

*** 我看不到如何创建 JS Fiddle,所以我添加了 css 和 HTML。

@charset "UTF-8";
/* CSS Document */


#wrap1 { width: 1000px; height: 100px; background-color:#F9C6C7; margin-left:auto; margin-right:auto; margin-top: 1px; }
#wrap1 table { width:1000px; }

.first { float:right; padding-top: 10px;}
.third { float:left; }

#wrap2_wrapper { width: 1000px; height: 250px; background-color:#000000; margin: 0 auto; }
#wrap2_wrapper img { padding-top:1px; border: none; max-height: 100%; margin: 0 auto;}


#wrapperMain { width: 1000px; min-height: 2000px; background-color:#ffffff; margin-left:auto; margin-right:auto; margin-top: ; padding-top: 5px; }
#wrapperMainvideos { width: 1000px; min-height: 1100px; background-color:#ffffff; margin-left:auto; margin-right:auto; }

#wrapperMain1 { width:1000px; height: 1000px; background-color:#ffffff; }
#wrapperMain2	{ width:1000px; height: 250px; background-color:#ffffff; }
#wrapperMain2 p { font-family:open-sans; font-size:14px; color:#000000; font-weight:100; }
#wrapperMain2_subleft2 { width:auto; height: 200; background-color:#F6BE44; }
#wrapperMain2_subright2 { width:auto; height: 200; background-color:#F6BE22; }

#wrapnews2 #wrapnews3 {border-bottom: 3px solid #4588ba; margin-bottom:10px;}

#wrapnews2 { width:1000px; height:810px; background-color:#ffffff; margin: 0 auto;  }
.wrapperMain2news { width: 1000px; height:810px; background-color:#ffffff; margin: 0 auto; }
.wrapnewsrightbar2 { width: 250px; height:auto; float:right; background-color:#ffffff; }

#wrapperMain3 { width:auto; height: 350px; background-color:#ffffff; }
#wrapperMain3 p { font-family:open-sans; font-size:14px; color:#000000; font-weight:100; }
#wrapperMain3_subleft3 { width:auto; height: 200; background-color:#F6BE78; }
#wrapperMain3_subright3 { width:auto; height: 200; background-color:#F6BE23; }

#wrapnews3 { width: 1000px; height:800px; background-color:#ffffff; margin: 0 auto; }
.wrapperMain3news { width: 510px; height:750px; background-color:#ffffff; float:left; }
.wrapnewsrightbar3 { width: 400px; height:750px; float:right; background-color:#fff666; }
.wrapnewsrightbar3 p { font-family:open-sans; font-size:14px; color:#000000; font-weight:100; }

#wrapperMain4 { width:auto; height: 350px; background-color:#ffffff;}
#wrapperMain4 p { font-family:open-sans; font-size:14px; color:#000000; font-weight:100; }
#wrapperMain4_subleft4 { width:auto; height: 200; background-color:#F6BE55; }
#wrapperMain4_subright4 { width:auto; height: 200; background-color:#F6BE99; }

#wrapnews4 { width:1000px; height:810px; background-color:#FABE55; margin: 0 auto; }
.wrapperMain4news { width: 510px; height:810px; background-color:#F7BD44; float:left; }
.wrapnewsrightbar4 { width: 250px; height:auto; float:right; background-color:#F3AE54; }

#wrapperMain5 { width:auto; height: 200px; background-color:#ffffff; }
#wrapperMain5 p { font-family:open-sans; font-size:12px; color:#000000; font-weight:100; }
#wrapperMain5_subleft5 { width:auto; height: 200; background-color:#F6BE01; }
#wrapperMain5_subright5 { width:auto; height: 200; background-color:#F6BE25; }
#wrapperMain6 { width:auto; height: 300px; background-color:#F6BEB28; }

#wrap2 { width: 1000px; height: 300px; background-color:#ffffff; margin-left:auto; margin-right:auto; margin-top: 5px; }
#sub_left2 { width: 500px;height: 300px;float: left;background-color: #ffffff;margin-top: 5px;margin-left: 2px;color: #000000;font-family: open-sans;font-style: normal;font-weight: 300; text-decoration: none;
}
#sub_right2 {width:450px; height:280px; float:right; background-color:#ffffff; margin-top:5px; margin-right:2px; }
h3 { font-family: 'Open Sans'; font-size:12px; font-weight:100; color:#000000; }

#wrap3 { width: auto; height:80px; background-color:#ffffff; margin-left:auto; margin-right:auto; margin-top: 5px; }

#menu { width: 1000px; height: 50px; margin-left:auto; margin-right:auto; }
#menu img { margin: 0 auto;  }

.nav { border:0px solid #ccc; border-width:0px 0; list-style:none; margin:0; padding:0; text-align:center;
}
.nav li { display:inline;}
.nav a { display:inline-block; padding:10px; font:open-sans; font-size: 20px; font-weight:300; color:#000000; text-decoration:none; }

 
#wrap4_slider1 { width:1000px; height: 250px; background-color:#fffccc; margin-left:auto; margin-right:auto; margin-top: 5px; }
#wrap4_slider1 cycle-slideshow img { margin-left:auto; margin-right:auto; }

#wrap_main1 { width:1000px; height:250px; margin-left:auto; background-color:#ffffff; margin-right:auto; margin-top:5px;  }
#sub_left1 { width: 500px; height: 280px; float:left; background-color:#ffffff; margin-top: 5px; margin-left: 2px; }
#sub_right1 { width:450px; height:280px; float:right; background-color:#ffffff; margin-top:5px; margin-right:2px; }
#wrap_main1 #sub_right1 a { padding-top:10px; border: none; display: block; margin: 0 auto; }

#wrapvideos { width: 850px; height: 1100px; margin: 0 auto; margin-top: 2px;  }

.wrapshows0 {width: 1000px; height: 1000px; background-color:#ffffff; margin: 0 auto; }

th,td {margin: 0;text-align: center;border-collapse: collapse;outline: 1px solid #e3e3e3;}

td { padding: 5px 10px;}

th{background: #666;color: white;padding: 5px 10px;}

td:hover { cursor: pointer; background: #666; color: white;}

#main1_sub_left { width:500px; height: 350px; float:left; background-color:#ffffff; margin-top: 15px; margin-left:5px; }
#main1_sidebar { width:400px; min-height: 600px; float:right; background-color:#ffffff; margin-top: 20px; }

#wrap_main2 { width: 500px; height: 300px; float:left; background-color:#ffffff; margin-top: 12px; margin-left:5px; }

#wrap_34 { width:1000px; height:300px; background-color:#ffffff; margin-bottom:  }
#wrap_main3 { width: 500px; height: 300px; float:left; background-color:#ffffff; margin-top: 10px; margin-left:5px; }
#wrap_main4 { width: 450px; height: 280px; float: right; background-color:#ffffff; }
#wrap_main4 a img { margin: 10px 0px 20px 0px; }


#wrap_main5 { width: 500px; height: 300px; float:left; background-color:#ffffff; margin-top: 5px; margin-left:5px; }

#social_media { width: auto; height: 100px; background-color:#C7C5C5;; margin-left:auto; margin-right:auto; margin-top: 20px; }
#social_media table { margin:0 auto; padding-top:15px; }

#footer {width:auto; height:50px; margin:auto; background-color:#888888; margin-top: 5px; }
#footer p { font-family: 'Open Sans'; font-size:12px; font-weight:100; color:#000000; padding: 20px 0px 0px 10px;  }
#footer p1 { font-family: open-sans; font-size:12px; font-weight:100; color:#000000; padding: 20px 0px 0px 10px; }
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
 "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta charset="UTF-8">
<title>Welcome to SoulTrain Radio</title>

<link rel="stylesheet" type="text/css" href="STRv1.css">

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script src="http://malsup.github.com/jquery.cycle2.js"></script>
<script src="http://malsup.github.io/jquery.cycle2.center.js"></script>

</head>

<body>

<div id="wrap1">
<table width="500" border="0">
 <tr>
  <td class="first"><img src="titlesListenLive.png" width="200" height="80" alt=""/></td>
  <td class="second"></td>
  <td class="third"><audio controls autoplay>
    <source src="http://93.190.141.15:7003/live?type=.mp3" type="audio/mp3">
  Your browser does not support the audio element.</audio></td>
 </tr>
</table>
  
  </div><!--wrap1 -->


<div id="wrap2_wrapper">
<img src="STRBristol_Logo.jpg" width="1000" height="250" alt=""/></div><!--wrap2_wrapper -->



<div id="menu">
<ul class="nav">
  <li><a href="index.html">HOME</a></li>
  <li><a href="shows.html">DJs &#038; SHOWS</a></li>
  <li><a href="events.html">EVENTS</a></li>
  <li><a href="about.html">ABOUT</a></li>
  <li><a href="news.html">NEWS</a></li>
  <li><a href="gallery.html">GALLERY</a></li>
  <li><a href="videos.html">VIDEOS</a></li>
  <li><a href="contact.html">CONTACT</a></li>
</ul>
</div>

<div id="wrap4_slider1"> 
<div class="cycle-slideshow"
data-cycle-fx=scrollHorz
    data-cycle-timeout=8000
data-cycle-center-horz=true
    data-cycle-center-vert=true>
    <img src="slider3.jpg" width="1000">
</div><!--cycle-slideshow -->
</div><!--wrap4_slider1 -->

<div id="wrapperMain"> 
<hr> 

<div id="wrap_main1"> 
<div id="sub_left1"> <img src="easter-poster.jpg" width="450" height="280" alt=""/></div>
<div id="sub_right1"> <a href="https://yplanapp.com/bristol/funk-up-your-good-friday-46369/" data-yplan="widget" data-width="450px"></a></div> 
</div><!--wrap_main1 -->

<br>
<br>
<div id="wrap2">
 <hr>
<div id="sub_left2">  
<h2> SOULTRAIN HISTORY... </h2>
<p>History 
Quoted by massive attack as early influencers on the ‘ Bristol sound ‘ the origins of Soultrain can be traced back to the early 1970’s which a BBC radio 6 documentary reported Soultrain DJ importing funk 45's and creating an underground scene whilst everybody else was into pop or punk / heavy rock. Local author Chris Brown has penned a book " suited and booted " acknowledging brothers Steve & Adrian Ashby & Paul Alexander as movers and shakers back in the day!   
</p>

<p> <a href="about.html" title="More..." target="_blank">More...</a> </p>


 <hr> </div>

<div id="sub_right2"> <iframe width="450" height="260" src="https://www.youtube.com/embed/dcR1gwRRbQc" frameborder="0" allowfullscreen></iframe><h3>Soultrain at Motion Bristol.. <a href="videos.html" title="Videos" target="_blank">More...</a></h3> </div>
</div><!--wrap2 -->

<div  id="main1_sidebar"> <a class="twitter-timeline" href="https://twitter.com/STRBristol" data-widget-id="697848027965480961">Tweets by @STRBristol</a> <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
</div>

<br>


<div id="main1_sub_left" > <p>"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."</p><p>"At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non recusandae. "</p></div>

<br>

<div id="wrap_main2"> <hr>  <p>"Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?"</p> <hr></div>
<br>

<div id="wrap_34">
<div id="wrap_main3"> <hr> <p>"But I must explain to you how all this mistaken idea of denouncing pleasure and praising pain was born and I will give you a complete account of the system, and expound the actual teachings of the great explorer of the truth, the master-builder of human happiness. No one rejects, dislikes, or avoids pleasure itself, because it is pleasure, but because those who do not know how to pursue pleasure rationally encounter consequences that are extremely painful. Nor again is there anyone who loves or pursues or desires to obtain pain of itself, because it is pain, but because occasionally circumstances occur in which toil and pain can procure him some great pleasure. To take a trivial example, which of us ever undertakes laborious physical exercise, except to obtain some advantage from it? But who has any right to find fault with a man who chooses to enjoy a pleasure that has no annoying consequences, or one who avoids a pain that produces no resultant pleasure?"</p> <hr></div>

<div id="wrap_main4"> <a href="advertise.html"><img src="advertise_str.png" width="450" height="300" alt=""/></a></div>
</div><!--wrap_34 -->
<BR>
</div><!--wrapperMain -->

<div id="social_media">
<table width="1000" border="0">
  <tbody>
    <tr>
      <th scope="col"><img src="tune_in.png" width="150" height="50" alt=""/></th>
      <th scope="col"><img src="facebook_icon.png" width="150" height="50" alt=""/></th>
      <th scope="col"><img src="instagram_icon.png" width="150" height="50" alt=""/></th>
      <th scope="col"><img src="mixcloud_icon.png" width="150" height="50" alt=""/></th>
      <th scope="col"><img src="twitter_icon.png" width="150" height="50" alt=""/></th>
    </tr>
  </tbody>
</table>
</div><!-- Social_media -->

<div id="footer">
<p>© 2016 SoulTrain Radio. All Rights Reserved.</p>
<p1>Created - Cr8tive M8di4 </p1> 
</div>


<script src="//yplanapp.com/affiliate/v1/widget.js"></script>
<script>
  YPlan.register({
    partnerId: 'a-partner-id',
    medium: 'backlink',
  });
</script>
</body>
</html>

最佳答案

去除轮廓

th, td {
    border-collapse: collapse;
    margin: 0;
    outline: 1px solid #e3e3e3; // remove this line
    text-align: center;
}

移除鼠标悬停时的背景

td:hover {
    background: #666 none repeat scroll 0 0; // remove this line
    color: white;
    cursor: pointer;
}

关于html - 图像周围有白色边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35490139/

相关文章:

PHP file_get_contents,在include之前对包含的文件执行PHP

html - 文本区域内的按钮与文本重叠

javascript - 如何通过 jquery 函数命名动态创建的文本框?

jquery - 鼠标悬停不会在生产环境中触发 jquery 动画

html - 无序列表元素不会定位

javascript - 有人可以解释为什么这个错误发生在我的导航栏上吗?

javascript - 使用 JavaScript/CSS3 制作横幅广告的汽车行驶动画

html - 从 CSS 中排除元素

css - Yii2 - DetailView 小部件向左浮动

html - 如何让表格中的字符保持在最前面