自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(36)
  • 问答 (5)
  • 收藏
  • 关注

apache2.4配置虚拟主机和ssi

之前在2.2上配置过,最近要升级到2.4,有些不太一样的地方。先说开启ssi,这个跟2.2差不多:1.打开 LoadModule include_module modules/mod_include.so2.在 DirectoryIndex [b]index.shtml[/b] index.html加入黑体部分3.打开AddType text/ht...

2015-09-22 11:16:28 372

在rhel5.4上安装openoffice和swftool

[color=red][b]“有两种东西不该被发明出来,一个是linux,一个是javascript,自从有了它们,一些叫程序员的人就再没好日子过了”[/b][/color]大多数步骤和报错都信息直接google就行了,没啥复杂的,不过在安装swftool时,在./configure之前,需要执行一下 sudo /sbin/ldconfig /usr/local/lib 一下。。。...

2012-04-25 10:31:48 135

读《牛奶--谎言与内幕》

[b]作者并不反对食用乳制品,只是反对欧洲奶商宣传的每人每天要食用3,4份乳制品的忽悠人的观点,估计“每天一斤奶,强壮xx人”也属于这种忽悠吧,更何况欧洲奶的质量远好于天朝的呢![/b]1.乳制品的一个优点之一并非来自奶类本身,而是来自其发酵产生的细菌--乳酸杆菌。这些微生物唯一且有文献依据的功效在于,它们对感染性腹泻及因服用抗生素所引起的腹泻有治疗作用。但是这些研究中,并非都使用酸奶,有...

2012-03-21 21:27:06 397

原创 tomcat启动时卡住了

事情是这样的,我为BeanNameUrlHandlerMapping编写了一个拦截器,并且在配置文件了进行了配置。但是我提交svn的时候,只提交了配置文件,没有提交这个拦截器类。结果别的同事更新了工程后,程序无法启动。tomcat控制台输出停在了:log4j:WARN No appenders could be found for logger (org.springframewo...

2011-12-03 19:23:54 425

原创 客户端服务端同为cxf,报org.apache.cxf.common.i18n.UncheckedException: No operation was fou

异常:[color=red]org.apache.cxf.common.i18n.UncheckedException: No operation was found with the name {http://impl.service.ws.mywebapp.com/}validCodeReq.[/color]我看了下wsdl里,有名为 validCodeReq的operation呀...

2011-09-20 14:19:08 956

原创 cxf做客户端时,报 javax.xml.bind.JAXBException: "" doesnt contain ObjectFactory.class

整个异常信息中,还有个错误提示:[error] IOException during exec() of compiler "javac". Check your path environment variable.在网上查了查,是这个原因:“CXF tools need javac to compile the generated source files.Please ad...

2011-09-19 17:58:05 1794

原创 诊断进程连接数据库的情况

方法一:watch 'lsof -i :1521' 实时查看连接到这个数据库端口的进程,找到连接比较多的那个,记住pid,然后ps -ef | grep 进程号 查看进程详请。方法二:ps -x 查询正在执行的进程,然后我想查看pid为12345的进程的数据库连接情况,netstat -anpt |grep 1521 |grep 19185 |wc -l每次显示出结...

2011-06-17 12:33:28 119

原创 【转】去除输入框内容的所有空格

原文地址 http://www.devcurry.com/2010/11/remove-all-white-space-using-javascript.html[code="html"]Remove Whitespaces using JavaScript by DevCurry.com function removeWhitespaces() ...

2011-06-14 09:48:08 126

原创 用java发送http请求

一种方式是用开源组件httpclient另一种是用jdk自带的类,下面只说下自带类的用法:[code="java"]package test;import java.io.IOException;import java.io.OutputStreamWriter;import java.net.HttpURLConnection;import java.net.UR...

2011-04-22 09:54:33 89

原创 编译运行spring-data-document

想看看spring与mongodb结合起来如何使用。从 https://github.com/SpringSource/spring-data-document 上下载demo用eclipse3.6-javaee版本打开demo的根目录右键点 spring-data-document-parent, run as --> maven install控制台出现警告:[...

2011-04-11 13:09:38 82

原创 【翻译】Spring Web Services 2 - Part II ( Marshalling , UnMarshalling using JAXB)

原文地址: http://panbhatt.blogspot.com/2011/03/spring-web-services-2-part-i.htmlIn second part of the series, we will talk about how to use Marshaller's in order to automatically convert your request ...

2011-03-18 09:18:44 88

原创 【翻译】Spring Web Services 2 - Part I

This is an introductory article, in a three part series which illustrates the use of Spring Web Services in a Java/J2EE Application.All the Examples has been created by using Spring 3, Spring Web Se...

2011-03-18 09:15:08 118

原创 获得本周截止到当前为止,所有用户的签到次数

[code="sql"]select t.usermobile, themeId, to_char(trunc(sysdate, 'iw'), 'yyyy-mm-dd') begintime, to_char(trunc(sysdate, 'iw') + 6, 'yyyy-mm-dd') endtime, count(distin...

2011-03-17 14:18:27 173

原创 【翻译】CriteriaBuilder and Dynamic Queries in JPA 2.0

A major new feature of Java EE 6 is JPA 2.0 and in particular the addition of the Criteria API which provides the ability to dynamically construct object-based queries.This resolves some of the pr...

2011-03-17 09:57:13 102

原创 【翻译】Serialization / Marshalling / Deflating in JAVA

原文地址: http://www.dzone.com/links/r/serialization_marshalling_deflating_in_java.htmlWriting Java Objects or keeping the state of Objects into DataBase or Files (In Binary Format) is known as Serial...

2011-03-14 10:52:29 111

原创 【翻译】10 Interview questions on Singleton Pattern in Java

原文地址: http://www.dzone.com/links/r/top_10_interview_questions_on_singleton_pattern_i.htmlSingleton pattern is one of the most common patterns available and it’s also used heavily in Java. This is ...

2011-03-14 10:49:04 130

原创 【翻译】Exercise for Object-Oriented Programming Concepts

原文地址: http://extreme-java.blogspot.com/2011/02/exercise-for-object-oriented.htmlFor all those programmers who are new to Java and have read some book but need some Java exercise or Java Tutorial c...

2011-03-03 14:31:15 116

原创 【翻译】Hello World with Apache Commons Digester

原文地址: http://kushanxp.blogspot.com/2011/02/hello-world-with-apache-commons.htmlThis example will shows how to get started with Apache Commons Digester.What is Apache Commons Digester?Sim...

2011-03-03 13:46:51 82

原创 【翻译】Hello World with Java Architecture for XML Binding - JAXB

原文地址: http://kushanxp.blogspot.com/2011/03/hello-world-with-java-architecture-for.htmlWhat is JAXB?JAXB (Java Architecture for XML Binding) facilitates you to read or write to a XML file. sinc...

2011-03-03 13:24:37 111

原创 【翻译】Abstract Classes Have Constructors

1) In Java , we have default constructors provided for classes by the compiler (in case one is not declared).2) The abstract classes can't be instantiated by using the new operator because they do...

2011-02-28 12:59:24 390

原创 【翻译】Why String is immutable in Java

原文地址: http://javarevisited.blogspot.com/2010/10/why-string-is-immutable-in-java.htmlThis is one of the most popular interview question on String in Java which starts with discussion of What is imm...

2011-02-28 11:27:10 119

原创 【翻译】java verbose options

原文链接: http://extreme-java.blogspot.com/2011/01/java-verbose-options-for-running.htmlThere are basically three sub parameters with the javac verbose parameter:verbose参数有三个基本的子参数:-verbose:clas...

2011-02-28 09:53:02 157

原创 如何判断iframe中的页面加载完毕

var a = document.getElementById('aaa');var iframeLoad = function(){ alert('IFRAME加载完成了!!');}if(!a.addEventListener){ a.attachEvent('onload', iframeLoad)}a.addEventListener('load'...

2010-11-18 17:28:26 1093

原创 用javascript判断上传图片的大小

[code="js"] var f = document.getElementById('file');f.onchange = function(){ var i = new Image() , f_val = f.value , isImg = /jpg|gif/i.test( (f_val.match(/\.(\w+)$/)[0]).toLowerCase()...

2010-08-17 14:49:04 74

原创 使用word2007时遇到的一个奇怪问题

打开一个doc文档后,如果在编辑期间切换到别的窗口,那么切回来时,就无法使用鼠标改变光标的位置了。。。。上网查了查,最后确定是 powerdesigner12.5的word插件导致的问题,解决方法如下:先从 Word 左上角菜单打开 Word Options,如果可以切换到 Add-ins 的设置上,则将Sybase - Power Designer 12.5 的 COM 加载删除掉,...

2010-08-17 14:25:32 80

MANIFEST.MF文件的Class-Path

刚才准备给一个小程序打成jar文件来运行,在弄MANIFEST.MF文件的Class-Path属性是费了些功夫,总结一下,文件内容大概如下:Manifest-Version: 1.0Class-Path: . abc-parser_lib/ abc-parser_lib/htmlcleaner2_1.jarMain-Class: cn.hjj.abc.NewsParser...

2010-04-17 19:13:43 786

gwt与hibernate集成时遇到的问题

------------------------3月25日-------------------------------------老是报这么个异常:com.google.gwt.user.client.rpc.SerializationException: Type 'org.hibernate.collection.PersistentBag' was not included in ...

2010-03-25 16:38:11 115

在windows系统上通过xmanager远程控制RHEL5

通过xmanager远程控制linux,网上的教程很多。但是具体到 RHEL5,就会有些出入。拿我遇到的情况来说,RHEL5的/etc/X11/目录下没有xdm文件夹(可能网管装系统的时候没给装上)。所以要安装,如果通过yum来安装的话,一般情况下是不行的,要先更改 yum 的源才可以。改源的方式网上很多。改好后执行:yum install xorg-x11-xdm根据...

2010-03-19 16:07:09 116

导入.dmp文件时遇到的一个问题

在pl/sql developer中导入.dmp文件怎么都不行,看了下log,发现导入的过程中,表都被跳过了,可是我的数据库里没有这些表啊,权限也够,怎么也不行呢?最后实在没办法了,尝试在命令行里用imp命令导,也不行,后来加了个参数ignore=y,搞定。。。。这是为什么呢?...

2010-03-06 19:31:03 177

原创 查看各表空间的使用情况

今天要建库倒表了,首先查看数据库各个表空间的情况:[code="sql"]SELECT c.tablespace_name tablespace_name, ROUND(a.bytes/1048576,2) total_size,ROUND((a.bytes-b.bytes)/1048576,2) used_size,ROUND(b.bytes/1048576,2) free_size...

2010-02-12 09:14:08 174

原创 关于一个使用pl/sql developer远程连接数据库的问题

今天在win2003上装完oracle10g后,在服务器上用plsql developer可以连接数据库,但是在客户端机器上却怎么都连不上,总是报tns找不到或是什么适配器错误啥的。一开始觉得是win2003自带的防火墙引起的问题,但是telnet了一下1521端口,发现是通的,就没再理会,后来折腾了好多别的办法,都无法解决这个问题。最后同事把防火墙给关闭,靠。。。解决了。。。window...

2010-02-11 17:56:04 94

原创 函数参数传递时的想当然

[code="js"]function setName(obj) {obj.name = “Nicholas”;obj = new Object();obj.name = “Greg”;}var person = new Object();setName(person);alert(person.name); //”Nicholas”[/code]记得某...

2010-01-19 10:01:40 69

删除文件夹和统计文件夹大小

[code="java"]//删除文件夹 public static void fileDelete(File file) throws Exception { if (!file.exists()) { log.debug("文件或目录不存在!"); return; } i...

2009-05-15 11:08:56 121

我的firefox常用插件

:wink: web developerfirebugdownloadhelperfireshotie tab感觉firefox真是挺好用的,可惜firefox2暂时还有内存泄露问题,经常占用我3,4百兆的内存。。。期待ff3 :lol: ...

2008-03-11 16:38:52 223

linux下mysql的一些常用命令

1:使用SHOW语句找出在服务器上当前存在什么数据库: mysql> SHOW DATABASES;2:创建一个数据库MYSQLDATA mysql> CREATE DATABASE MYSQLDATA;3:选择你所创建的数据库 mysql> USE MYSQLDATA; (按回车键出现Database changed 时说明操作成功!)4:查看现在的数据库中存在什么...

2008-03-03 09:05:54 94

not null不能写成notnull。。。。

在创建表的时候,比如:[code="sql"]create table test(id int(11) not null primary key);[/code]如果把not null 写成notnull那就不对了~primary key 也不能连起来写!

2008-02-25 16:11:56 109

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除