jsp页面显示效果
2013-11-03 17:40
274 查看
1输入框提示信息
<input type="text" value="请输入帐号" onmouseover=" this.value='' ">
<input type="text" onfocus="this.value='';" onblur="if(this.value=='')this.value='默认显示的字'; " value="默认显示的字" name="sousuo" size="24" class="lb_search" />
<script language="javascript" type="text/javascript"> var d1 = document.getElementById('d1'); function show() { d1.style.display = 'block'; } function hidden() { d1.style.display = 'none'; } </script> <body> <p>asdfasdfasdfsdfdfg<a href="#" onmouseover="show()" onmouseout="hidden()">鼠标放上来看看</a>sdfhdfh</p> <div id="d1"></div> </body>
2针对不断刷新页面,用来对按钮变色
<% UserManagerService userManagerService = new UserManagerService(); ResultSet functionlist = userManagerService.queryFunctions(user); /* 根据用户名进行查询所有菜单*/ String flag=request.getParameter("flag"); System.out.println(flag); while(functionlist.next()){ String functionUrl = functionlist.getString("FUNCTION_URL").trim(); String functionName = functionlist.getString("FUNCTION_NAME"); int id = functionlist.getInt("FUNCTION_ID"); %> <h1><a href="${pageContext.request.contextPath}/<%= functionUrl%>?flag=<%=id %>" style='<%= flag!= null && !"".equals(flag) && id==Integer.parseInt(flag)?"color:yellow;":"" %>' > <%=functionName %> </a></h1>
因为有可能会出现乱码,所以用id来传参数
相关文章推荐
- JSP页面,实现上传图片即时显示效果
- jsp页面中使用了<%=new java.util.Date()>但是不显示效果
- Eclipse编辑jsp不显示预览效果页面
- jsp页面底部使用<jsp:include>或<%@ include>引用其他页面,主页面显示效果异
- jsp页面不识别EL表达式,显示效果为EL表达式自身字符串
- jsp查询页面和结果页面在同一页面显示和交互
- jsp页面中实现分页效果
- 在jsp页面中实现递归显示树状结构(树状bbs)
- 在服务器调试过程中,JSP页面无法正常显示
- action中的list在JSP页面如何显示问题的总结
- java 中jsp页面中时间显示格式
- 在jsp页面上写js函数自动显示系统时间
- 在JSP页面中通过JS动态显示时间程序
- 为什么在tomcat6.0下显示正常的jsp页面在tomcat 7.0里中文全是乱码?怎么样才能解决
- JSP页面查询显示常用模式[转贴]
- JSP页面用EL表达式取值或小脚本取值时,用三目运算符判断显示
- JSP页面显示乱码解决方法
- 在jsp页面中引入日期插件后效果出现乱码
- JFreeChart画图+jsp页面显示
- jsp页面中显示word/excel格式的文档的方法