<input type="hidden" value="<%=wz%>" id="ycwz" />
<img id="zdybtts" style="float:none" src="<%=btt%>"/>
<script language="javascript" type="text/javascript">
var ycwz = document.getElementById("ycwz").value;
if(ycwz!=null||ycwz!="")
{
document.getElementById("zdybtts").style.floatStyle = ycwz;
}
</script>
<%
}
else
{
%>
<img style="position: relative; top: -3px;" src="../App_themes/Zone1/image/title.gif" />
<%
}
%>
我是在页面加载的时候:给<img id="zdybtts" style="float:none" src="<%=btt%>"/> 一个float值,但是页面上没有反应
LTFunction.setFloatStyle=function(obj,style)
{
var sty=obj.style;
if('cssFloat' in sty){
obj.style.cssFloat=style;
}else if('styleFloat' in sty){
obj.style.styleFloat=style;
}else{
throw 'set float style:'+style+'error.';
}
}
w3c: obj.style.cssFloat="left";