`
文章列表
首先在命令行里关闭mysql服务  net stop mysql 然后在命令行里,以不检查权限的方式启动;mysqld --skip-grant-tables 界面会一直停留在那,不用理它。 然后重新开打一个命令提示符的窗口(CMD)用空密码方式使用root用户登录 MySQL;mysql -u root直接进去了,  修改root用户的密码;mysql> update mysql.user set password=PASSWORD('新密码') where User='root';mysql> flush privileges;mysql> quit 然后 按住 ...

maven集成tomcat7

只要在pom.xml文件中添加如下代码: <build> <plugins> <!-- 配置Tomcat方便运行 --> <plugin> <groupId>org.apache.tomcat.maven</groupId> <artifactId>tomcat7-maven-plugin</artifactId> <version>2.1</version> <configuration> ...
选中目录使用Ctrl+H调出窗口,选择File Search输入要查找的字符串,右下解有replace可以跳到替换的窗口实现替换。
以下内容为转载内容,源文出自:http://bbs.csdn.net/topics/390314580 我也搞了几年JAVA了,由于一向懒惰,没有成为大牛,只是一普通程序猿,不爱玩社交网站,不爱玩微博,唯独喜欢百度贴吧,潜水很久了,手痒来给新人分享下从 ...
这里上传的是maven版附件,需要的可以下载。
本实例要用的到jar包:   如果你用的是maven,pom.xml文件如下:   <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <mode ...
代码不贴了,有要看的直接下载代码。有maven版和eclipse版。建议学一下maven,很好用。 eclipse的要在mysql中的test中创建一张表 create table upload (id int not null auto_increment primary key, dir varchar(200), realName varchar(200), name varchar(200), type varchar(100));
//调用方法 //<input type="text" style="border:1px solid #999;" onclick="fPopCalendar(event,this,this)" onfocus="this.select()" readonly="readonly" /> var gMonths=new Array("一月","二月","三月","四月","五月&qu ...
http://search.maven.org/#search%7Cga%7C1%7C https://repository.sonatype.org/index.html#welcome
import java.awt.Color; import java.awt.Font; import java.awt.Graphics; import java.awt.image.BufferedImage; import java.util.Random; import javax.imageio.ImageIO; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSessi ...
1.request对象 客户端的请求信息被封装在request对象中,通过它才能了解到客户的需求,然后做出响应。它是HttpServletRequest类的实例。 1 object getAttribute(String name) 返回指定属性的属性值   2 Enumeration getAttributeNames() 返回所有可用属性名的枚举   3 String getCharacterEncoding() 返回字符编码方式   4 int getContentLength() 返回请求体的长度(以字节数)   5 String getContentType() ...
package yzr.thread; public class ProducerConsumer { public static void main(String[] args) { Contains c = new Contains(); // 创建线程并启动线程 new Thread(new Producer(c)).start(); new Thread(new Producer(c)).start(); new Thread(new Producer(c)).start(); new Thread(new Co ...
基本数据类型分为四类八种:整型(byte,short,int,long)、浮点型(float,double)、字符型(char)、布尔型(boolean)。 运用switch时应注意以下几点: 1、case穿透,使用break来避免 2、多可case可以合并到一起 3、default可以省略,但不推荐省略。 java的类中定义成员变量时,可以对其初始化,若不对其进行初始化将会给定默认值。默认值如下: 数据类型 取值 byte 0 short 0 int 0 long 0L float 0.0F double 0.0D char ...
//配置文件:config.properties放在classpath下 jdbc_driver=com.mysql.jdbc.Driver jdbc_username=root jdbc_password= jdbc_url=jdbc\:mysql\://localhost\:3306/student?useUnicode\=true&characterEncoding\=utf-8 //读取properties文件的工具类 package com.util; import java.io.IOException; import java.util.Propert ...
//java连接数据库相关类,要测试成功需要导入mysql连接的jar包 //数据库连接类 package com.jdbc; import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public class DBC { // private static final String DBDRIVER="oracle.jdbc.driver.OracleDriver"; // private static final Strin ...
Global site tag (gtag.js) - Google Analytics