asp首页滚动图片不能全显示

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了asp首页滚动图片不能全显示相关的知识,希望对你有一定的参考价值。

首页里图片只能4张图来回滚动,再上传别的就替换了怎么让所有上传的图都滚动 代码:

<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>横向滚动</title>
<style type="text/css">
<!--
.heigh18 line-height: 18px;

body
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;

body,td,th
font-family: 宋体;
font-size: 12px;

-->
</style>
</HEAD><body scroll="no">
<TABLE width=740 border=0 align=center cellPadding=0 cellSpacing=0 style="">
<TBODY>
<TR>
<TD><DIV id=demo style="OVERFLOW: hidden; WIDTH: 100%; height:130px; COLOR: #ffffff">
<TABLE width="316" border=0 align=left cellPadding=0 cellSpacing=0 cellspace="0">
<TBODY>
<TR>
<TD id=demo1 vAlign=top><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<%i=1
do while not rs.eof%>
<td align="center"><table width="60%" height="141" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="70%" height="141" align="center"><table width="169" height="130" border="0" align="center" cellpadding="0" cellspacing="1">
<tr>
<td width="167" height="128" bgcolor="#FFFFFF"><table width="100%" height="128" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="167" height="126" align="center" valign="middle" bgcolor="#B40100"><a style="cursor:hand;" onClick="javascript:window.open('view.asp?ClassLayer=<%=rs("p_ClassLayer")%>','','width=650,height=500,resizable=no,resizable=yes,scrollbars=yes');"><img src="picture/<%=rs("p_Picture1")%>" width="165" height="124" border="0"></a></td>
</tr>
<tr></tr>
</table></td>
</tr>
</table></td>
<td width="30%" align="center"> </td>
</tr>
</table>
<img src="images/space.gif" width="1" height="0"></td>
<%if i mod 3=0 then%>
</tr>
<tr></tr>
<tr>
<%end if%>
<%rs.movenext
i=i+1
if i>MaxPerPage then exit do
loop
%>
</tr>
</table></TD>
<TD id=demo2 vAlign=top> </TD>
</TR>
</TBODY>
</TABLE>
</DIV>
<script language=JavaScript src="scrollpic.js"></script>
</TD>
</TR>
</TBODY>
</TABLE>
</TD>
</TR>
</TABLE>

</BODY>
</HTML>
<%end if%>
网站www.bjminzs.com

参考技术A 那你就把所有的图都读出来

如何显示全高背景图片?

我有一个照片类型(不是风景)背景图像,宽度为979像素,高度为1200像素。我想将它设置为向左浮动并显示100%全图像高度固定,而无需向上/向下滚动(无论内容长度如何)。

这是我的CSS代码,但它不起作用:

img, media {
    max-width: 100%;
}

body {
    background-color: white;
    background-image: url('../images/bg-image.jpg');
    background-size: auto 100%;
    background-repeat: no-repeat;
    background-position: left top;
}
答案

您可以使用您拥有的代码执行此操作,您只需确保将htmlbody设置为100%高度。

但是:ぁzxswい

http://jsfiddle.net/kevinPHPkevin/a7eGN/
另一答案

CSS可以使用background-size:cover;

但要更详细并支持更多浏览器......

使用像这样的宽高比:

html, body {
    height:100%;
} 

body {
    background-color: white;
    background-image: url('http://www.canvaz.com/portrait/charcoal-1.jpg');
    background-size: auto 100%;
    background-repeat: no-repeat;
    background-position: left top;
}

aspectRatio = $bg.width() / $bg.height();

另一答案
FIDDLE

以上是关于asp首页滚动图片不能全显示的主要内容,如果未能解决你的问题,请参考以下文章

Android中仿淘宝首页顶部滚动自定义HorizontalScrollView定时水平自动切换图片

Android中仿淘宝首页顶部滚动自定义HorizontalScrollView定时水平自动切换图片

网页代码图片显示问题!请高手进来看看

QT 做图片缩略显示 滚动条下拉 怎么实现动态加载下面的图片?

求教php首页上想让两张图片循环滚动代码怎么写啊

CSS3 object-fit视频和图片比例自适应