- 浏览: 10005 次
- 性别:
- 来自: 深圳
最新评论
文章列表
package com.cn.xml;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;
import org.w3c.dom.Document;
public class XMLParseUtil {
private static final Document docum ...
bootstrap上提供的popover.js 即弹出框的组件,用法参考官网吧,这里不做介绍,
想说明的是有这样一个需求: 鼠标移等到图片上面时,弹出一些介绍,以及点击图片时发送一个超链接请求,
这跟视频网站上浏览某个视频是一样的道理,下面是代码:
<img class="show-info-img " alt="培训主题"
src="${ filePath }${ topic.photo }" data-toggle="popover"
data-placement=& ...
前端js需要对汉字进行编码
var topicName=$("#search-topic").val();
if(!topicName){
alert("培训主题不能为空!");
}else{
window.location.href="searchTopic.do?type="+trainType+
"&topicName="+encodeURI(encodeURI(topicName));
}
后台需要对其进行解码
try{
topicName=URLDecoder ...
判定空值
var exp = null;
if (!exp)
{
alert("is null");
}
判定未定义
var exp = undefined;
if (typeof(exp) == "undefined")
{
alert("undefined");
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
<hibernate-configur ...
package com.util;
import org.hibernate.SessionFactory;
import org.hibernate.boot.registry.StandardServiceRegistryBuilder;
import org.hibernate.cfg.Configuration;
/*用于创建SessionFactory的工具类,官方写法*/
public class HibernateUtil {
private static final SessionFactory sessionFactory=bulidSessionF ...
### set log levels ###
#log4j.rootLogger = debug , stdout , D , E
log4j.rootLogger = debug , stdout , D
### output to the console ###
log4j.appender.stdout = org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Target = System.out
log4j.appender.stdout.layout = org.apache.log4j.PatternL ...
jdbc_driverClassName=com.mysql.jdbc.Driver
jdbc_url=jdbc:mysql://192.168.1.110:3306/edu_platform?useUnicode=true&characterEncoding=utf-8
jdbc_username=root
jdbc_password=123456
再