<img src=" " name="image" border=0 id="img"/>
<br />
<input name="picture" type="file" id="picture" onchange="img.src=this.value" />
</form>
不需要按钮,直接触发onchange事件就能实现~~~
方法1:function openMaxWindow(){window.open("asd.html","","width=1280px,height=960px,top=0px,left=0px")//其中width,height根据您当前设置的分辨率来调整(以上数据匹配1280*1024)top,left是指窗口刚打开时左上角所在的坐标}方法2(不推荐):function openMaxWindow(){window.open("xxx.html","","fullscreen=1")}根据楼主您的需求可以选择性使用.. 希望对您有帮助...<script language="JavaScript">function expandit(objname,objPic){
if(objname.style.display == "none"){
objPic.src = "<%=request.getContextPath() %>/images/-.gif"
objname.style.display = ""
}
else{
objPic.src = "<%=request.getContextPath() %>/images/+.gif"
objname.style.display = "none"
}
}
</script>
<table width="128" border="0" cellpadding="0" cellspacing="0"
bgcolor="#FFFFFF">
<tr>
<td width="135" height="25" align="left" style="cursor: hand"
onclick="expandit(treeitem1,treepic1)">
<img src="<%=request.getContextPath() %>/images/+.gif" id="treepic1" width="11" height="11"
hspace="5" border="0" /> <font color="blue">客户信息</font>
</td>
</tr>
<tr>
<td>
<table border="0" cellpadding="0" cellspacing="0"
bgcolor="#FFFFFF" width="100%" id="treeitem1"
style="display: none">
<tr align="right">
<td height="25">
<img src="" width="4" height="8" hspace="5" />
<a href="/FCKDemo/addNews.jsp?isOpen=true" target="contentpage">新闻添加</a>
</td>
</tr>
<tr align="right">
<td height="25">
<img src="" width="4" height="8" hspace="5" />
<a href="news/newslist.jsp" target="contentpage">新闻管理</a>
</td>
</tr>
</table>
</td>
</tr>
</table>
试试这种 感觉能比你的简单些吧
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)