自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

^_^-Beluga, ^_^-Stefli

Everyday is full of joy!

  • 博客(248)
  • 论坛 (82)
  • 收藏
  • 关注

原创 Translate C++ Dijkstra to Javascript version

The C++ Dijkstra is at:http://www.cnblogs.com/tanky_woo/archive/2011/01/19/1939041.htmlCalculate the path from 1 to 5!Here is the Javascript version which is translated from above vers

2011-12-02 13:01:20 1354

原创 Set wlan for mobile devices in Wn7

Add a bat file(wlan.bat) with content:netsh wlan set hostednetwork mode=allow ssid=testt key=12345678netsh wlan start hostednetworkpause

2011-09-26 12:26:22 730

原创 "your computer needs to restart" when install Windows 8 on Virtualbox

When i install the Windows 8 Preview on Virtualbox, it always stopped at black screen with "your computer needs to restart, params.....".A

2011-09-16 08:48:38 1792

原创 消防安全培训总结

1、 哨子:对于家中有老人,特别是独居老人或有慢性病老人的的非常重要,一旦老人独自在家发生意外(摔伤、生病、紧急情况)而导致行动不便或无力呼救时,随手可拿的哨子将能够引起邻居或救援人员注意。如遇地震等情况,哨子也能够起到呼救功能。再配个手电给老人放床头。 2、 厨房:用肥

2011-08-09 08:54:50 3207

转载 Keycode list

Just for reminder.key: { a: {code: 65}, b: {code: 66}, c: {code: 67}, d: {code: 68}, e: {code: 69}, f: {code: 70}, g: {code:

2011-08-01 17:17:38 583

原创 Create menu by javascript dynamically

There are many ways to create menu dynamically:1. Spit url by "/", then create menu for each part.You can search the solution from internet,

2011-07-27 13:24:46 614

原创 Sample of HTML 5 game development

Just a sample of HTML 5 game development. var VehicleGame = function() { var ctx; var goRight = false, goLeft = false, paus

2011-07-26 17:43:16 630

原创 Convert string to JSONObject by net.sf.json library

Just for reminder.JSONObject json = (JSONObject) JSONSerializer.toJSON( jsonTxt );

2011-07-19 18:04:22 1642

原创 An effective way to use pattern to instead of multiple if else statements

We often face many if-else statements during the development, that's a little boring.We can use pattern to change this, such as Strategy, an

2011-07-19 15:14:39 678

原创 Assign privilege to SA for drawing the relationship diagram in MsSQL

When click "Database relationship diagram" in MsSQL, warning "此数据库没有有效所有者" will be shown up.To fix this issue, just execute below sql to ass

2011-07-14 15:03:42 457

原创 You should know this about google(plus)

203.208.46.29 picadaweb.google.com203.208.46.29 lh1.ggpht.com203.208.46.29 lh2.ggpht.com203.208.46.29 lh3.ggpht.com203.208.46.29 lh4.ggpht.c

2011-07-07 12:33:38 532

原创 Display the google map in jQuery ui dialog

Use the default settings, the google map can be displayed in a separate page. But, cant be displayed in the jQuery dialog. After debug in Firebug, i found that the major javascripts are never be load

2011-06-30 15:48:00 1184

原创 Three linkage menu for Province, City, County

To load adzone faster, we need to use ajax to load the province, city or county when its parent changed.Here is the major code:1. Main page<%@ page language="java" contentType="text/html; chars

2011-06-23 17:46:00 1846

转载 How to open the dialog out of iframe by using jquery dialog

The solution is from http://stackoverflow.com Once, i want to trigger the dialog in iframe, and want it to be openned in the parent page. but it always displayed in the iframe. Here is a solut

2011-06-23 10:06:00 1385

原创 Continue & break function in .each() function

If you want to do "continue" in an .each() loop, you can use below code segment to implement it.  $(div).each(function (index, el) { if (index == 0) { return true; }}); 

2011-06-22 10:24:00 620

转载 Client-side table sorting for flexigrid

Writer:   Dustkicker  ----------------------------------------------------------------------------------------I wrote a function to perform sorting of the table loc

2011-06-16 14:42:00 868

转载 事务的传播性

1.Required:共享型若1处在一个事务中调用了2,则2直接和1在同一个事务中。若1没有任何事务,则系统会默认给2创建一个新事务。此策略适合大多数情况。2.RequiredNew:独立型若1在一个事务中调用了2,则系统先将1的事务挂起,不管、之后为2设置一个新事务,执行完毕后恢复1的事务。若1没有事务,则会为2新开一个事务。3.Mandatory:强制共享型若1处在一个

2011-06-13 22:02:00 715

原创 Specify the column on one-to-many

If we want the relatioship is TestParent.testNo = TestChild.testNo, do not use the identity column "id".We should specify the columns in mapping file, such as:<class name="com.stefli.model.TestPar

2011-06-09 13:56:00 630

原创 How to format date/datetime in struts2

<br />1. Use param<br /><s:textfield name="order.entryDt"> <s:param name="value" ><s:date name="order.entryDt" format="MM/dd/yyyy" /></s:param> </s:textfield> <br /> <br />2. Use i18n, you should enable i18n and add i18n properties first.<br />i18n

2011-05-27 11:02:00 911

原创 org.springframework.security.AuthenticationCredentialsNotFoundException: An Authentication object was not found in the SecurityC

<br />Reference:<br />1.5. I get an exception with the message "An Authentication object was not found in the SecurityContext". What's wrong? This is a another debug level message which occurs the first time an anonymous user attempts to access a p

2011-05-24 12:50:00 5621 1

原创 Client can't access Jboss server, the port is not accessable.

<br />Run the JBoss server via:<br /> <br />run.bat -b 0.0.0.0<br /> <br />Then the server can be accessable via http://IP:PORT<br /> 

2011-05-20 10:07:00 737

原创 Jboss 4.2 & hibernate java.lang.NoSuchFieldError: INSTANCE

<br />Just remove the hibernate-annotation.jar from lib

2011-05-19 18:07:00 1562

原创 org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorre

<br />Exception:<br />org.hibernate.StaleObjectStateException:   Row   was   updated   or   deleted   by   another   transaction   (or   unsaved-value   mapping   was   incorrect)<br /> <br />Add a hidden field for hibernate version.<br /> 

2011-05-05 15:52:00 5085 1

原创 How to get bean from tag component

<br />Please refer to:<br />@SuppressWarnings("unchecked") @Override public Component getBean(ValueStack stack, HttpServletRequest request, HttpServletResponse response) { ServletContext servletContext = ServletActionContext .getServletCont

2011-05-04 10:09:00 768

原创 How to let IE support HTML5 tags(aside, section, header, footer, etc..)

<br />Import a html5.js with content below (also can download this js from remysharp.com/html5-enabling-script):<br />// html5shiv MIT @rem remysharp.com/html5-enabling-script// iepp v1.6.2 MIT @jon_neal iecss.com/print-protector/*@cc_on(function(m,c){

2011-04-21 12:17:00 943

原创 Multi IE Tester

<br />http://utilu.com/IECollection/

2011-04-21 11:13:00 594

原创 Build administrative area via Json

<br />We want to build a json string to store the administrative area data, the format would bevar threeSelectData={"省份":{"val":"","items":{"城市":{"val":"","items":{"区县":""}}}},"河北":{"val":"130100","items":{"石家庄市":{"val":"130200","items":{"市辖区":"130101","长安

2011-04-18 23:17:00 578

原创 Customize tag lib 2

<br />We also can customize the tag lib using component class, here are the steps:<br />1. Define the component<br />package com.stefli.core.component.taglib;import java.io.IOException;import java.io.Writer;import javax.servlet.http.HttpServletReques

2011-04-02 13:08:00 520

原创 Customize tag lib 1 (freemarker)

Want to customize a tag lib, we need to do follow the steps:1. Define the component (UIBean)package com.stefli.core.component.taglib;import javax.servlet.http.HttpServletRequest;import javax.servlet.http.HttpServletResponse;import org.apache.struts2.

2011-04-02 13:02:00 582

原创 Fix the issue: JVM terminated. Exit code=-1

<br />When restart the Blackberry plug-in, an error happened with "JVM terminated. Exit code=-1.".<br />We can specified the jdk to eclipse.ini to fix this issue, so solution as below:<br /> <br /><br />Add below:<br />"<br /><br />-vm<br />D:/software/jdk

2011-03-11 13:18:00 574

原创 One public IP for different contexts via apache rewrite

<br /><br /><VirtualHost *:82><br />    #ServerName www.example.com<br />    #ServerAlias example.com<br />    #ServerAdmin webmaster@example.com<br /> <br />    RewriteEngine On<br />    RewriteRule ^/aContext(.*)$ http://%{SERVER_ADDR}:8080/bpmApprovalMo

2011-03-01 11:12:00 454

原创 getString() always return 255 when column is larger than 255

<br />I have created a table with a column(varchar(1200), then insert some data to this table.<br />When use Jdbc to get the value of this column, it always return 255 chars, so, we need to solve<br />it via:<br /> <br />select convert(text, columnName) fr

2011-02-18 14:39:00 1029

原创 org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start()

<br />Solution:<br /> <br />Just remove the folder under "X:/Documents and Settings/username/workspace/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes"<br /> <br />then restart the Eclipse

2011-01-13 19:54:00 7324 3

原创 Cool, i have fixed the "Access violation writing to 0x00000008" of BlackBerry Simulator(JDE5.0)

<br />This issue only happened in Jde 5.0, so i can't use 9700 or other devices.<br /> <br />I have searched many articles, and no solution found. <br />Some one told me to run "Clean.bat", or restart the Simulator can solve it, but after many tries, i sti

2011-01-10 13:59:00 1353

原创 How to setup Apache + Python + Django + mod_wsgi

<br /><br />Apache + Python + Django + mod_wsgiInstallation Guideline<br /> <br />1.  InstallApache<br />Install the apache follow the instruction.<br /> <br />2.  InstallPython<br />Add “D:/software/Python27” and “D:/software/Python27/Scripts”to %

2010-12-22 14:46:00 731

原创 How to setup Apache and mod_python and django

<br />Here is the tutorial:<br /> <br /> <br />1. Install Apache2.2<br />Please refer to other article!<br /> <br />2. Install mod_python<br />Please go to mod_python site to download the compatible version, then install it.<br />After the installation, a

2010-12-22 12:30:00 566

转载 Add Locales

<br />Quote: http://code.google.com/p/winelocale/wiki/AddLocalesToDebianAddLocalesToDebian  How to add locale code pages to Debian or Ubuntu systemsIntroduction<br />Generally, Debian, and especially its cousin Ubuntu, attempt to make using Linux as easy a

2010-12-14 13:17:00 544

转载 教你怎么把骗子弄哭

<br /><br />教你怎么把骗子弄哭<br />1.收到骗子要你汇款的短信后先别忙著删除,看看他的卡号是什么银行的,并登陆此银行的网上营业厅,输入该骗子的卡号,密码随便填写,只要3次错误,此卡在24小时之间是不能进行任何的交易了(就是被冻)<br />2.先查出这个手机号的城市,然后找到那个城市的同性恋交友网站,注册帐号,联系方式留下那个手机号码。<br />3.在当地的房屋出租网站发帖,市中心两室一厅,月租300,急出手。24小时开机,同样留下那个电话。<br />4.某银行职员同样收到短信“请把钱

2010-12-13 09:39:00 503

转载 OuterHTML implementation in Firefox

<br />Here is a sample:<br /><html><head><title>FireFox OuterHTML Implementation</title><mce:script type="text/javascript"><!--if(typeof

2010-12-09 10:11:00 389

原创 How to access url via wifi in blackberry emulator

<br />Add below code to url:<br />;interface=wifi<br /><br /><br /><br />StreamConnection conn = (StreamConnection) Connector.open("http://192.168.87.72/data.xml;interface=wifi");<br /> <br />Then we can access the data from above url via blackberry emulat

2010-11-30 16:18:00 512

空空如也

初学者,希望得到你的帮助!

发表于 2003-10-14 最后回复 2012-11-23

主板自检出问题!如何处理!

发表于 2003-10-18 最后回复 2012-11-23

这个如何解决?冲突问题!

发表于 2003-10-21 最后回复 2012-11-23

救救我吧!!!

发表于 2003-10-22 最后回复 2012-11-23

windows日志中报 Downshift detected

发表于 2006-04-11 最后回复 2012-11-23

使用fdisk的时候,明明显示39026(40G),分了主分区(23%)后,后面却不能分区了~

发表于 2004-11-14 最后回复 2012-11-23

DISK BOOT FAILURE, INSERT 老问题,新现象~!

发表于 2004-12-18 最后回复 2012-11-23

在线求救!!!一个很棘手的问题!

发表于 2003-06-03 最后回复 2012-11-23

如何通过asp程序,post一个xml文档到dll中,并返回结果!

发表于 2004-07-02 最后回复 2012-11-23

各位高手帮帮忙吧!~~~~~~~~~~~~````紧急!!!!!!!!在线等待!!!!

发表于 2003-08-22 最后回复 2012-11-23

Axis1.2 还是Nullpointer的问题

发表于 2008-09-16 最后回复 2008-09-17

新增800条记录,数据表迅速增大很快,附:sp_spaceused查询结果,希望帮忙分析一下。

发表于 2008-06-04 最后回复 2008-09-17

tomcat起不来,据说与hibernate有关系。附Exception

发表于 2008-05-28 最后回复 2008-06-04

使用dom4j解析和保存xml时,为什么会解析出错,多写一些字符进去?

发表于 2007-12-10 最后回复 2008-01-27

Struts中,同一页面两Date输入框,一个可以自动绑定,一个不行?

发表于 2007-06-27 最后回复 2008-01-27

JDOM保存xml文件,为什么总是先删除文件,然后再写内容呢?能够直接刷新部分数据!

发表于 2007-12-06 最后回复 2008-01-03

Oracle已经安装好,现在要添加组件?用install.exe该如何处理?会不会删除掉现在的文件?

发表于 2007-12-14 最后回复 2007-12-14

系统时间对的,java.util.Date得到的时间确是错误的??

发表于 2006-05-23 最后回复 2007-04-11

发布几个自己瞎搞的类似J2ME游戏设计的js类

发表于 2007-01-21 最后回复 2007-01-22

如何获取telnet的数据

发表于 2006-03-30 最后回复 2006-03-30

二进制的异或处理问题

发表于 2006-02-22 最后回复 2006-02-22

很奇怪的硬盘问题,丢失10G空间·

发表于 2006-01-24 最后回复 2006-02-14

ActiveMainMenuBar能改成透明的么?可以加背景图片么??

发表于 2005-04-05 最后回复 2005-04-25

xml中encoding丢失的问题~

发表于 2005-04-19 最后回复 2005-04-20

断开Tcp连接?

发表于 2005-03-05 最后回复 2005-03-05

断开网络

发表于 2005-03-03 最后回复 2005-03-04

搞个mp3播放器玩玩~

发表于 2005-02-21 最后回复 2005-02-24

http://username:password@url/test?a=b的地址怎么去取得参数呢?

发表于 2005-01-18 最后回复 2005-02-04

窗口之间的方法使用?

发表于 2005-01-24 最后回复 2005-01-24

使用NTSVC.OCX,就是写NT服务的,怎么总是vb6.exe,我想改成我的程序名???

发表于 2004-12-28 最后回复 2004-12-28

郁闷了,Session在变~·~,同样程序,同样2003系统,只是不同的服务器~!~

发表于 2004-12-16 最后回复 2004-12-16

使用sp_who查出一个进程ID为69,是什么原因造成的???

发表于 2004-12-14 最后回复 2004-12-15

关于treeview的问题,重载treeview的时候,出现“集合中的关键字不唯一”

发表于 2004-12-14 最后回复 2004-12-14

建立webservice,编译asmx文件得到dll文件,请问在服务器上如何布置,客户端才能使用??

发表于 2004-10-25 最后回复 2004-11-02

建立webservice,编译asmx文件得到dll文件,请问在服务器上如何布置,客户端才能使用??

发表于 2004-10-25 最后回复 2004-11-02

模拟confirm中点击取消按钮的事件语句有么??

发表于 2004-10-22 最后回复 2004-11-01

webservice的post问题~

发表于 2004-10-26 最后回复 2004-10-27

按教程制作helloworld.java,编译通过,但是页面中不能调用,何解?

发表于 2004-10-15 最后回复 2004-10-18

Jmail本地发送,无乱码,上传服务器,标题出现乱码,内容正常!!!!!!!!何故???

发表于 2004-09-06 最后回复 2004-09-06

刚刚发现一个问题,不知道是为什么~~~~~~

发表于 2004-09-04 最后回复 2004-09-06

空空如也

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

TA关注的人 TA的粉丝

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