我想知道如何将我的图像滑块或“轮播”设置为始终距离浏览器左侧30%。当页面变小时,我也不想让我的图像滑块缩小。
答案 0 :(得分:0)
你有一些看起来像这样的代码:
<div id="container">
<div class="" style="width: 1130px; margin: 0px auto;">
... blah blah other code ...
这基本上是你的旋转木马的中心。
将该边距更改为margin: 0 30% 0 auto
,因此它始终是左侧30%。所以它看起来像:
<div id="container">
<div class="" style="width: 1130px; margin: 0 30% 0 auto;">
... blah blah other code ...