摘要: System.Net.ServicePointManager.ServerCertificateValidationCallback = New System.Net.Security.RemoteCertificateValidationCallback(AddressOf ValidateServerCertificate)Public Function ValidateServerCertificate(ByVal sender As Object, ByVal certificate As System.Security.Cryptography.X509Certificates.X5 阅读全文
posted @ 2012-06-05 10:13 Liujx 阅读(425) 评论(0) 推荐(0) 编辑
摘要: mysql误删除root用户或者忘记root密码时的解决办法一不小心删除了mysql的root用户,在网上找了很多办法都没有解决,由于mysql数据库比较多,重装又太麻烦,所以一直在努力尝试各种方法,最后终于成功了。步骤如下:1、先结束mysqld进程#killall mysqld不加载grant_tables而进入mysql#mysqld_safe --skip-grant-tables &进入mysql#/usr/local/mysql/bin/mysqlmysql use mysqlDatabase changedmysql select * from user;Empty set 阅读全文
posted @ 2010-12-24 16:27 Liujx 阅读(2840) 评论(0) 推荐(0) 编辑
摘要: 通常Ajax使用Json从服务端载入数据。在服务端 可以利用拼结 Json数据字符串返回客户端。 数据不存在特殊字符 如:' " \ 等特殊字符可以正常呈现。如果当所获取的数据包含这些特殊字符时,Json数据在客户端解析就会出现问题。解决办法,可以用第三方 Newtonsoft.dll 下载,生成Json数据。示例后台 ashx 文件代码(vb.net 实现,C#同理,语法不同):[代码]前端 Javascript 代码:url:为请求的地址,此处为ashx的地址。prefix:为页面InputID前缀部分,inputid=prefix+后端对应的对象成员名称,达到自动赋值的目的。param 阅读全文
posted @ 2010-12-11 09:31 Liujx 阅读(2313) 评论(0) 推荐(0) 编辑
摘要: 压缩你的javascripthttp://closure-compiler.appspot.com/home 阅读全文
posted @ 2010-12-11 09:10 Liujx 阅读(261) 评论(1) 推荐(0) 编辑
摘要: 导出Excel按钮protected void btnExport_Click(object sender, EventArgs e){string connstring = “User Id=test;Password=123;Data Source=test”;//实例化OracleConnection对象using (OracleConnection conn = new OracleConnection(connstring)){conn.Open();OracleDataAdapter oda=new OracleDataAdapter();DataSet ds = new Data 阅读全文
posted @ 2010-09-29 17:28 Liujx 阅读(245) 评论(0) 推荐(0) 编辑
摘要: Contents [hide] 1 1xx Informational 2 2xx Success 3 3xx Redirection 4 4xx Client Error 5 5xx Server Error 6 See also 7 References 8 External links [edit] 1xx InformationalRequest received, continuing process.[2]This class of status code indicates a provisional response, consisting only of the Status 阅读全文
posted @ 2010-08-21 11:41 Liujx 阅读(424) 评论(0) 推荐(0) 编辑
摘要: 利用 window.print() 打印页面内容,其中一些是要打印的(不显示在页面),面另一些只是为显示用的,可以利用CSS 来控制实现,代码如下:style type="text/css" @media print { .PPRT { visibility:visible; margin:0 } .SRCN { visibility:hidden; display:none} } @media screen { .PPRT { visibility:hidden} .SRCN { visibility:visible; display:inline} } /style页面两个d 阅读全文
posted @ 2010-03-19 17:25 Liujx 阅读(204) 评论(0) 推荐(0) 编辑
摘要: 函数如下:如果返回none或 #ff0000 则表示客户端没有安装jre.copy 自 Snapabug.jsscript type="text/javascript" function getJREVersions() { function _64(_65) { var _66="JavaWebStart.isInstalled."+_65+".0"; if(!ActiveXObject){return false} try{ return(new ActiveXObject(_66)!=null) } catch(exception) { return false } } functi 阅读全文
posted @ 2010-02-05 16:53 Liujx 阅读(567) 评论(0) 推荐(0) 编辑
摘要: .fixedCSS {  position:absolute ;  top:expression(eval(document.body.scrollTop));} 阅读全文
posted @ 2009-10-19 15:08 Liujx 阅读(163) 评论(0) 推荐(0) 编辑
摘要: select datesold from efreshwhere next_day(to_date(to_char(datesold,'yyyymmdd'),'yyyy/mm/dd'),2)= next_day(to_date(to_char(sysdate-7,'yyyymmdd'),'yyyy/mm/dd'),2) 语法 :next_day( date, weekday )1表示星期日,2表示星期一,依此类推,最大为7 此统计结果: 上一周的所有销售日期。 阅读全文
posted @ 2009-09-14 16:17 Liujx 阅读(227) 评论(0) 推荐(1) 编辑