流的readLine方法用于读取一行数据,但不包括换行符。 因此,读文件的时候要自己加上。如: InputStreamReader isr = new InputStreamReader(new FileInputStream(fileName,"utf-8"); brin = new BufferedReader(isr); while((s = brin.readLine())!=null){ but+=s.toString()+System.getProperty("line.separator");//当前系统的换 ...
  • 17:46
  • 浏览 (25)
  • 评论 (0)
function printing() { alert(document.getElementById('report1').outerHTML); var nw = window.open('','','width=800,height=600'); nw.document.open("text/html","GBK"); nw.document.write("<object classid='CLSID:8856F961-340A-11D0-A96B-00C04FD705A2' id='wb'height='0' width='0'></object ...
  • 10:31
  • 浏览 (28)
  • 评论 (0)
请求参数的来源   1. 请求 URL 的查询串, 如 /localhost/abc/test?abc=ddd&bbb=ccc, 在问号后面的字符串   2. POST 请求时, 如果 Content-Type = "application/x-www-form-urlencoded", 则参数来自请求内容(格式同查询串)   对于第一种情况, 请求参数可以在任何情况下使用 getParameter 系列方法读取, 采用 ISO-8859-1 编码   对于第二种情况, 则有点复杂, 它涉及到 ServletRequest 以下几个方法   getParameter 系列方法   getCha ...
  • 19:29
  • 浏览 (30)
  • 评论 (0)
模态窗口的新增代码 <script> window.name = "myname"; </script> 模态窗口的部分代码——增加表单的target属性 <form name="form1" method="post" action="insert.asp?up" target="mywin"> <table width="100%" border="0"> ...
  • 10:15
  • 浏览 (44)
  • 评论 (0)
1、Javascript弹出子窗口 可以通过多种方式实现,下面介绍几种方法 (1) 通过window对象的open()方法,open()方法将会产生一个新的window窗口对象 其用法为: window.open(URL,windowName,parameters); URL: 描述要打开的窗口的URL地址,如何为空则不打开任何网页; windowName:描述被打开的窗口的民称,可以使用'_top'、'_blank'等内建名称,这里的名称跟<a href="..." target="...">里的target属性是一样的。 parameters:描述被打开的窗口的参数值,或 ...
  • 17:26
  • 浏览 (269)
  • 评论 (0)
如果是在帧内的页面,就要使用parent.document.getElementById("")的到帧对象。 parent.document.getElementById("").src=""指定该帧指向的页面。 如果是当前页面中有帧,要获得帧对象,直接用document.getElementById("")就可以了。
  • 17:17
  • 浏览 (33)
  • 评论 (0)
修改remoteDesigner目录下的defaultLicense.jar中的systemconfig.xml,添加数据源。以后在客户端打开设计器时,就不需要再配数据源了 <?xml version="1.0" encoding="UTF-8"?> <REPORT> <CONFIG_MENU> </CONFIG_MENU> <CONFIG splashFile="designer/config/runqiansplash.jpg"> </CONFIG> <DATASOURCE> <DS1 config="password="aagea ...
  • 15:29
  • 浏览 (52)
  • 评论 (0)
同一个页面,在tomcat下正常,在websphere下报错: com.ibm.ws.jsp.JspCoreException: /report/showreport.jsp(80,80) JSPG0055E: 无法从名称 [.raq] 值 [%] 创建 xml 属性 at com.ibm.ws.jsp.translator.document.Jsp2Dom.getJspDocumentAsJspPage(Jsp2Dom.java:290) at com.ibm.ws.jsp.translator.document.Jsp2Dom.getJspDocument(Jsp2Dom.java:1 ...
  • 11:38
  • 浏览 (42)
  • 评论 (0)
在一个textarea中输入一段文字,保存到数据库后再到页面上取出来显示时,就无法显示换行了。 而放到textarea中,或者放到<pre>...</pre>之间,换行又可以正确显示。 在网上看了别人的帖子,说要把"\n"替换成"<br/>",试了无效。 这个问题应该怎么解决呀?
我想得到一个table里的每一行数据,格式如下: <tr> <td align='center' class='orang'>07098</td> <td width='35' align='center' class='yellow'>3</td> <td width='26' align='center' class='yellow'>7</td> </tr> 于是我写了这个程序,用来提取以<tr>开头,</tr>结尾的内容 String regEx=".+(<tr>.+</tr>).+"; Pattern p=Pa ...
super_094
搜索本博客
博客分类
最近加入圈子
存档
最新评论