0

我确定这可以追溯到基本的 web 101,我很惭愧地问,但我有一个有序的号码列表,我已经在图像下设置了。当您单击任何数字时,图像将变为不同的图像。

一切正常,直到我调整浏览器窗口的大小 - 数字保持在它们所在的位置(它们的位置是相对的)并且其他所有东西都移动到页面的中心(因为我希望它这样做)。

这是实时页面的链接 - http://thewiredlife.net/kelseytest/fish.html

<div id="sectionwrap" class="svw">
<ul>
<li><img src="images/fish_full.png" width="1024" height="602" alt="fish"></li>
<li><img src="images/fish_full_2.png" width="1024" height="602" alt="jj"></li> 
</ul></div>

#sectionwrap {
width: 1024px;
height:340px;
margin-left: auto;
margin-right: auto;
margin-top:20px;}

.svw {width: 50px; height: 102px;}
.svw ul {position: relative; left: -999em;}

.stripViewer {
position: relative;
overflow: hidden;
margin: 0 0 1px 0;
}
.stripViewer ul
margin: 0;
padding: 0;
position: relative;
left: 0;
top: 0;
width: 1%;
list-style-type: none;
}
.stripViewer ul li {
float:left;
}
.stripTransmitter {
overflow: auto;
width: 1%;
}
.stripTransmitter ul {
margin-top:6px;
margin-left: 60px;
padding: 0;
list-style-type: none;
}
.stripTransmitter ul li{
width: 20px;
float:left;
margin: 0 1px 1px 0;
}
.stripTransmitter a{
font-family: 'OpenSansLight', Helvetica, Arial, sans-serif;
font-size:14px;
text-align: center;
line-height: 22px;
color: #BCBCBC;
text-decoration: none;
display: block;
}

调整窗口大小时,有什么解决方案可以使数字跟随其余内容?谢谢 :)

4

1 回答 1

0

First- your numbers are not in the class you posted above, take a look at your source. Your numbers are inside stripTransmitter0. I would suggest making those numbers stand out a little more. Second - you've given it a witdh, now add a margin: 0 auto to center stripTransmitter0 just like sectionwrap.

于 2013-02-04T14:59:54.617 回答