A5下载 - 努力做内容最丰富最安全的下载站!

A5站长下载站

当前位置:A5下载 > 源码技巧 > phpwind > phpwind相册显示缩略图却不能显示大图解决方案

phpwind相册显示缩略图却不能显示大图解决方案

时间:2015-05-08 15:04作者:zhao人气:141

将下面的代码复制,然后新建一个htm文件,将其复制到里面保存,重命名为m_photos.htm,然后上传到到论坛的

appsphotostemplate

下面

<!-- A5源码资讯:http://down.admin5.com/info -->

<!--<? php print <<<EOT-->

<!--EOT;if($cssForum){print <<<EOT-->

<div class="c"></div>

<link rel="stylesheet" type="text/css" href="$pwModeImg/app.css" />

<!--EOT;}print <<<EOT-->

<script type="text/javascript">

var imgMaxWidth=710;

function ImgLoad()

{

var o = document.getElementById("imgview");//.getElementsByTagName("img")[0];

var pe = document.getElementById('imgpre');

if(o==null || pe == null || !pe.width)

{

setTimeout(ImgLoad, 400);

}else

{

if (pe.width>imgMaxWidth){

if (o.style.width){

o.style.width="";

}

o.width=imgMaxWidth;

o.removeAttribute("height");

o.style.cursor="hand";

o.vspace=5;

o.resized=1;

}

else

{

o.width=pe.width;

}

o.src=pe.src;

var next = getObj('next');

var pre = getObj('pre');

setTimeout(function(){

next.coords = '0 0 ' + ',' + o.width/2 + ',' + o.height;

pre.coords = o.width/2 + ' 0 ' + ',' + o.width + ',' + o.height;

},400);

}

}

</script>

<img id="imgpre" src="$photo[path]" style="position:absolute;left:-10000px" onload="ImgLoad()" />

<div id="content" class="fr">

<div style="padding:15px 15px 0;">

<div class="app-title cc">

<!--EOT;if($m == 'o'){print<<<EOT-->

<a href="{$basename}space=1" class="gray fr">进入个人空间浏览&raquo;</a>

标签phpwind,相册,显示,略图,不能,大图,解决方案,面的

相关下载

查看所有评论+

网友评论

网友
您的评论需要经过审核才能显示

公众号