- 博客(178)
- 资源 (1)
- 问答 (3)
- 收藏
- 关注
原创 java file copy
package sample;import java.nio.file.Files;import java.nio.file.Path;import java.nio.file.Paths;public class CopyExample1 {public static void main(String[] args) throws Exception {Path source = Paths.get("foo/bar/note.txt");Path target = Paths.get("temp/bar
2024-03-11 15:18:45
353
原创 Java create file
package sample;import java.nio.file.Files;import java.nio.file.Path;import java.nio.file.Paths;public class PathExample3 {public static void main(String[] args) throws Exception {Path path = Paths.get("temp/bar/note.txt");Files.createFile(path);}}
2024-03-11 15:08:03
428
原创 Interface Path
package sample;import java.nio.file.Path;import java.nio.file.Paths;public class PathExample1 {public static void main(String[] args) {Path p = Paths.get("C:/work/docs/note.txt");System.out.println(p);System.out.println(p.getRoot());System.out.println(p.ge
2024-03-11 14:33:36
343
原创 DAO Java
try {return con;try {\n" + e);if (smt!= null) {try {if (con!= null) {try {try {\n" + e);if (smt!= null) {try {if (con!= null) {try {try {
2024-03-10 13:56:58
908
原创 Spring Starter Project
/DependencyInjectionSample/src/main/java/com/example/demo/chapter03/used/Greet.java/DependencyInjectionSample/src/main/java/com/example/demo/chapter03/used/MorningGreet.java/DependencyInjectionSample/src/main/java/com/example/demo/chapter03/used/EveningGre
2024-03-02 11:09:26
453
1
原创 Dependency Injection
sprintf—Return a formatted stringsprintf(string$format,mixed...$values) :string|false
2024-03-02 09:46:46
354
原创 Servlet修改后可以不用重启Tomcat
Before1.Servlet (Hello.java)编译编译javac -encoding utf-8 -d ..\classes -sourcepath . chapter3\Hello.java生成Hello.class2.启动Tomcat3.运行http://localhost:8080/book/chapter3/helloServlet修改后可以不用重启Tomcat 的方法演示如下1.编写文件context.htmlC:...
2021-09-04 10:52:49
402
原创 Servlet编译
1.编译Servlet文件Hello.javajavac -encoding utf-8 -d ..\classes -sourcepath . chapter3\Hello.java生成Hello.class2.启动tomcat3.运行http://localhost:8080/book/chapter3/hello
2021-09-04 08:39:39
291
原创 javax.servlet不存在
1.编译Servlet (Hello.java)的时候,提示 javax.servlet不存在2.原因Classpath的设置有问题3.调查开始-输入cmd,输入下面代码echo %classpath%.;C:\Program Files\Java\jdk1.8.0_171\lib\tools.jar;C:\Program Files\Java\jdk1.8.0_171\lib\dt.jarC:\work\tomcat\lib\servlet-api.jar4.改..
2021-09-04 08:12:47
282
原创 Java throw throws
1.throwfunction内部throwsfunction外部2.throw 后面只能一次抛出一个异常throws可以一次抛出若干异常,异常之间用逗号分开
2021-03-05 11:10:01
94
1
原创 margin 0 auto
居中margin : 0 automargin-top:0;margin-right:auto;margin-bottom:0;margin-left:auto;
2020-11-23 09:07:29
194
原创 Android 网站页面内容控制在手机屏幕内
<meta name="viewport" content="width=640px, user-scalable=no, target-densitydpi=device-dpi">
2020-11-19 13:18:59
170
原创 PHP json_encode()
private $data =[......];echo json_encode($this->data[$id]);
2020-11-19 09:06:24
103
原创 this->Html
$this->Html->scriptStart(array('inline' => false));$this->Html->scriptEnd();$this->Html->css(filename [, ] );echo $this->Html->css('forms');<link rel="stylesheet" href="/css/forms.css" />
2020-11-18 16:43:34
127
原创 CakePHP find()
$this->model name->find('all',array('fields' => array('id','last_name','first_name'),'conditions' => array('Model.id' => 10),'order' => array('id' => 'asc'),'limit' =>...
2020-11-18 15:50:02
125
原创 PHP array_key_exists()
array_key_exists(mixed$key,array$array) :boolChecks if the given key or index exists in the array
2020-11-18 15:14:41
119
原创 CakePHP 3.9.3 autoRender
public $autoRender = false; Controller $autoRender = false action ↓ Web browser
2020-11-18 15:04:05
126
原创 PHP sprintf()
sprintf(string$format,mixed...$values) :string|false%02dE%02 包含0在内2位dintegerEscientific notation
2020-11-18 14:38:31
142
原创 CakePHP array
$name = array('Tom', 'Lili', 'Kate');print $name[0];print $name[1];print $name[2];$name = array('Tom' =>'CN', 'Lili' =>US, 'Kate' =>JP);print $name['Tom'];print $name['Lili'];print $name['Kate'];
2020-11-18 11:21:30
76
原创 CakePHP foreach
foreach( $arrayname as $key =>$value){print $key;print $value;print '<br />';}
2020-11-18 11:16:29
101
原创 CakePHP HTML helper link method
$this->Html->link('title', ['controller' => 'controllername ', 'action' => 'action name','parameter']);
2020-11-18 11:06:16
225
原创 Html Placeholder
index.html<!DOCTYPE html><html><body><h1>placeholder</h1><form action="/test.html"> <label for="phone">Enter a phone number:</label><br><br> <input type="tel" id="phone" name="pho..
2020-11-17 08:52:05
110
原创 notepad++ 代码带颜色
Settings----StyleConfiguratorSelect theme:BespinLanguage----P----PHP
2020-11-16 06:38:16
7975
原创 页面浮动按钮固定在右下角
footer.php<div style="z-index: 9999; position: fixed ! important; right: 0px; bottom: 0px;"><table width="100%" style="position: absolute; right: 0px; bottom: 0px;"><tr><td><ul> <li><a href="https://xxxxx...
2020-11-15 16:04:03
1614
Win10 Delphi Help.zip
2020-03-29
Active Reports表单label的位置移动后,运行程序之后,位置还是没有移动
2017-08-04
VB.Net 中ActiveReports连接数据库
2017-08-04
E-R图的画图工具,有没有比较好的?
2017-07-13
TA创建的收藏夹 TA关注的收藏夹
TA关注的人