CSDN论坛 > Java > Web 开发

能否动态改变 width的值? <td width="11%"></td>, 以及动态改变td 的数量? [问题点数:10分,结帖人ATCG]

Bbs2
本版专家分:185
Blank
黄花 2002年6月 其他数据库开发大版内专家分月排行榜第二
结帖率 99.74%
CSDN今日推荐
Bbs7
本版专家分:11015
Bbs2
本版专家分:185
Blank
黄花 2002年6月 其他数据库开发大版内专家分月排行榜第二
匿名用户不能发表回复!
其他相关推荐
我的htmlpage页
<div style="height: 15px; border-bottom: 1px solid gray"> <table> <tr> <td style="background-color: gray; width: 200px;"> </td> <td style="background-color: yellow; border-left:1px solid black; width: 100px;"> SI1 </td> <td style="background-color: gray; width: 200px;"> </td> </tr> </table>
JAVA面试题
面试题的学习,有助于帮助你<form action="servlet/addcourse" method="post" name="addform" onSubmit="return isValid()"> <table width="55%" align="center" border="1"> <tr> <td width="36%" align="center">课程号</td> <td width="54%">&nbsp;&nbsp;&nbsp;<input type="text" name="cid" size="16"><font color="red">*</font></td> </tr> <tr> <td width="36%" align="center">教学班号</td> <td width="54%">&nbsp;&nbsp;&nbsp;<input type="text" name="clnum" size="16"><font color="red">*</font></td> </tr> <tr> <td width="36%" align="center">课程名</td> <td width="54%">&nbsp;&nbsp;&nbsp;<input type="text" name="cname" size="16"><font color="red">*</font></td> </tr> <tr> <td width="36%" align="center">学分</td> <td width="54%">&nbsp;&nbsp;&nbsp;<input type="text" name="credit" size="16"></td> </tr> <tr> <td width="36%" align="center">课容量</td> <td width="54%">&nbsp;&nbsp;&nbsp;<input type="text" name="capacity" size="16"></td> </tr> <tr align="center">
隐藏表格<TD>
只隐藏某一个格TD width="16%" vAlign="middle" class="style2" style="display:none">看不到我
效果代码 电子商务专用
<style>#top a img{ border:0px; background: none repeat scroll 0 0 #ffffff;} #top a:hover img{ opacity: 0.3;cursor:hand; background: none repeat scroll 0 0 #000000;}</style> <div class="mc" style=";min-height:0px;"> <table cellspacing="0" cellpadding="0" width="990"> <tbody> <tr> <td height="5" width="491"> &nbsp; </td> <td width="10" height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> <tr> <td id="top" width="491"> <a href="http://mall.jd.com/index-36534.html" target="_blank"><img alt="" src="http://img13.360buyimg.com/cms/g13/M06/07/11/rBEhUlKUGYsIAAAAAACVBgMIHFQAAF8FADp1uEAAJUe282.jpg" /></a> </td> <td> &nbsp; </td> <td id="top" width="487"> <a href="http://obm1688.jd.com/" target="_blank"><img alt="" src="http://img12.360buyimg.com/cms/g14/M07/02/1F/rBEhVVKUDwsIAAAAAACddJ30vnUAAGE7wMJRywAAJ2M237.jpg" /></a> </td> </tr> <tr> <td height="5" width="491"> &nbsp; </td> <td height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> <tr> <td id="top" width="491"> <a href="http://mall.jd.com/index-18930.html" target="_blank"><img alt="" src="http://img14.360buyimg.com/cms/g15/M00/18/07/rBEhWlKUEXIIAAAAAACZNCKI2d0AAF8WQHH9DgAAJlM028.jpg" /></a><a href="http://obm1688.jd.com/" target="_blank"></a> </td> <td> &nbsp; </td> <td id="top" width="487"> <a href="http://mall.jd.com/index-23958.html" target="_blank"><img alt="" src="http://img12.360buyimg.com/cms/g15/M04/18/08/rBEhWVKUFP4IAAAAAACX7ABEnMAAAF8aQKiv08AAJgE072.jpg" /></a> </td> </tr> <tr> <td height="5" width="491"> &nbsp; </td> <td height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> <tr> <td id="top" width="491"> <a href="http://wohayo.jd.com/" target="_blank"><img alt="" src="http://img13.360buyimg.com/cms/g14/M08/03/00/rBEhVlKUKxwIAAAAAACamuFo6qkAAGFUQCZULYAAJqy405.jpg" /></a> </td> <td> &nbsp; </td> <td id="top" width="487"> <a href="http://mall.jd.com/index-43555.html" target="_blank"><img alt="" src="http://img11.360buyimg.com/cms/g14/M08/03/00/rBEhVlKUKyUIAAAAAAD6Jzf8LwsAAGFUQIJAewAAPo_402.jpg" /></a> </td> </tr> <tr> <td height="5" width="491"> &nbsp; </td> <td height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> <tr> <td id="top" width="491"> <a href="http://jenmick.jd.com/" target="_blank"><img alt="" src="http://img12.360buyimg.com/cms/g14/M04/03/01/rBEhVVKUQs8IAAAAAAFBFkrF15oAAGFsgGA-xMAAUEu343.jpg" /></a> </td> <td> &nbsp; </td> <td id="top" width="487"> <a href="http://wantdo.jd.com/" target="_blank"><img alt="" src="http://img13.360buyimg.com/cms/g13/M06/07/13/rBEhU1KURlYIAAAAAAFhUThMfSgAAF8uAGM5_gAAWFp811.jpg" /></a> </td> </tr> <tr> <td height="5" width="491"> &nbsp; </td> <td height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> <tr> <td height="5" width="491"> &nbsp; </td> <td height="5"> &nbsp; </td> <td height="5" width="487"> &nbsp; </td> </tr> </tbody> </table> </div>
max-width:100%在td 或 table-cell 的兼容解决办法
一直没太注意有这个坑,td或者table-cell的元素里,如果没有指定容器宽度,那么容器里的img标签max-width:100% 在IE7-11,以及firefox下会不理会max-width的限制,例如: max-width:100%不兼容小笔记-练小习 *{ margin: 0; padding: 0; border:0; } .img-wr
在ie7、ie8下 td th宽度解决方法
.title {background-color:#ccc;width: 150px} 哈哈 aa 大都会 bb adad alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快的拉拉alkjd阿拉快
JSP图书管理系统
项目使用说明 tushu是本书最一章的综合案例程序,在运行前请正确配置JDK和Tomcat,然后再复制tushu文件夹到Tomcat的webapps\examples 文件夹下即可。 本项目仅用于学习目的。读者若对项目有问题 请和我一起交流: <%@ page contentType="text/html;charset=gb2312" language="java"%> <html> <%@ include file="inc/conn1.jsp"%> <%@ include file="top.jsp"%> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>计算机图书--管理系统</title> </head> <body > <table width="900" border="0" align="center" cellpadding="0" cellspacing="0"> <!--DWLayoutTable--> <tr> <td width="39" rowspan="9" align="right" valign="top"><img src="image/y1.jpg" width="39" height="1007"></td> <td width="206" height="13"></td> <td width="7"></td> <td width="605"></td> <td width="7">&nbsp;</td> <td width="36" rowspan="9" valign="top"><img src="image/z1.jpg" width="36" height="1006"></td> </tr> <tr> <td height="108" valign="top"><table width="206" height="110" border="0" cellpadding="0" cellspacing="0" background="image/dongkuaif.gif"> <!--DWLayoutTable--> <tr> <td width="15" height="9"></td> <td width="181"></td> <td width="10"></td> </tr> <tr> <td height="86"></td> <td align="center" valign="middle"><span class="stylex"> <script language="JavaScript">var when=new Date(); document.write("<h4>"); document.write(when.getYear()+"年"); document.write((when.getMonth()+1)+"月"); document.write(when.getDate()+"日<br>"); document.write(when.getHours()+"时"); document.write(when.getMinutes()+"分"); document.write("</h4>"); </script></span></td> <td></td> </tr> <tr> <td height="15"></td> <td>&nbsp;</td> <td></td> </tr> </table></td> <td>&nbsp;</td> <td rowspan="3" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0"> <!--DWLayoutTable--> <tr> <td width="605" height="167" valign="top"><img src="image/tupic.gif" width="605" height="167"></td> </tr> </table></td> <td>&nbsp;</td> </tr> <tr> <td height="7"></td> <td></td> <td></td> </tr> <tr> <td colspan="2" rowspan="5" valign="top"> <table width="208" height="123" border="0" cellpadding="0" cellspacing="0" background="image/logn.jpg"> <!--DWLayoutTable--> <tr> <td width="8" height="24">&nbsp;</td> <td width="200">&nbsp;</td> </tr> <tr> <td height="99">&nbsp;</td> <td><%@ include file="denglu.jsp"%></td> </tr> </table> <table width="208" border="0" cellpadding="0" cellspacing="0" background="image/dongkuaid.gif"> <!--DWLayoutTable--> <tr> <td width="215" height="42">&nbsp;</td> </tr> <tr> <td height="277" align="center" valign="top"><%@include file="changxiao.jsp"%></td> </tr> </table> <br> <table width="208" height="356" border="0" cellpadding="0" cellspacing="0" background="image/chuxiao.gif"> <!--DWLayoutTable--> <tr> <td width="24" height="37">&nbsp;</td> <td width="184">&nbsp;</td> <td width="7"></td> </tr> <tr> <td height="293">&nbsp;</td> <td valign="top"><%@ include file="chuxiao.jsp"%></td> <td></td> </tr> <tr> <td height="24">&nbsp;</td> <td>&nbsp;</td> <td></td> </tr> </table></td> <td height="67"></td> </tr> <tr> <td height="187" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="image/link.gif"> <!--DWLayoutTable--> <tr> <td width="20" height="5"></td> <td width="495"></td> <td width="69"></td> <td width="21"></td> </tr> <tr> <td height="21"></td> <td valign="top"><%@ include file="scroll.htm"%></td> <td></td> <td></td> </tr> <tr> <td height="38"></td> <td>&nbsp;</td> <td></td> <td></td> </tr> <tr> <td height="105">&nbsp;</td> <td colspan="2" valign="top"><%@ include file="toplist.jsp"%></td> <td>&nbsp;</td> </tr> <tr> <td height="18">&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> </table></td> <td></td> </tr> <tr> <td height="11"></td> <td></td> </tr> <tr> <td height="242" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="image/tonew.gif"> <!--DWLayoutTable--> <tr> <td width="7" height="1"></td> <td width="591"></td> <td width="7"></td> </tr> <tr> <td height="33" colspan="3" valign="middle" bgcolor="#F7F7F7"><span style="font-size: medium">新进图书</span></td> </tr> <tr> <td height="10"></td> <td></td> <td></td> </tr> <tr> <td height="172"></td> <td valign="top"><%@ include file="newbooks1.jsp"%></td> <td></td> </tr> <tr> <td height="26"></td> <td>&nbsp;</td> <td></td> </tr> </table></td> <td></td> </tr> <tr> <td height="338" colspan="2" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0"> <!--DWLayoutTable--> <tr> <td width="605" height="4"></td> </tr> <tr> <td height="353" valign="top"> <%@ include file="new.jsp"%></td> </tr> <!--DWLayoutTable--> </table></td> </tr> </table> <%@ include file="end.jsp"%> </table> </body> </html>
JSP教材12334
dukebanner.html] <table border="0" width="400" cellspacing="0" cellpadding="0"> <tr> <td height="150" width="150"> &nbsp; </td> <td width="250"> &nbsp; </td> </tr> <tr> <td width="150"> &nbsp; </td> <td align="right" width="250"> <img src="duke.waving.gif"></td></tr></table><br> helloworld.jsp <%@ page info="a hello world example" %> <html> <head><title>Hello, World</title></head> <body bgcolor="#ffffff" background="background.gif"> <%@ include file="dukebanner.html" %> <table> <tr> <td width=150> &nbsp; </td> <td width=250 align=right> <h1>Hello, World!</h1> </td> </tr> </table> </body> </html>
extjs4 模板值和模板
extjs4 模板值和模板 1、append方法 Javascript代码 var tpl = new Ext.Template(//定义模板 '<table border=1 cellpadding=0 cellspacing = 0>', '<tr><td width=90>姓名</td><td width=90>{0}</td></tr>', '<tr><td>年龄</td><td>{1}</td></tr>', '<tr><td>性别</td><td>{2}</td></tr>', '</table>' ) //模板值和模板进行组合并将新生成的节点插入到id为'tpl-table'的元素中 tpl.append('tpl-table',['小王',25,'男']); var tpl = new Ext.Template(//定义模板 '<table border=1 cellpadding=0 cellspacing = 0>', '<tr><td width=90>姓名</td><td width=90>{0}</td></tr>', '<tr><td>年龄</td><td>{1}</td></tr>', '<tr><td>性别</td><td>{2}</td></tr>', '</table>' ) //模板值和模板进行组合并将新生成的节点插入到id为'tpl-table'的元素中 tpl.append('tpl-table',['小王',25,'男']);
IE浏览器解决table td 的宽度不生效问题
这样设置宽度,无论将宽度设为多大,在ie页面都没有一点反应。 但谷歌界面是好的。 解决方案:    [加个div设置一下宽度就好了] 又比如不能设置th的高度 只需要在整个完了之后在加一个空的
关闭