Skip to content

Instantly share code, notes, and snippets.

@enujo
enujo / web.xml
Last active February 11, 2017 15:09
[JAVA] Servlet 2.3 DTD
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app />
@enujo
enujo / web.xml
Created February 11, 2017 15:09
[JAVA] Servlet 2.2 DTD
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
<web-app />
@enujo
enujo / web.xml
Created February 11, 2017 15:16
[JAVA] Servlet DTD(2.2 ~ 3.1)
<!-- Servlet 3.1 -->
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1">
</web-app>
<!-- Servlet 3.0 -->
<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
@enujo
enujo / pom.xml
Created February 11, 2017 15:29
Java Servlet API, mysql connect
<!-- https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/javax.servlet.jsp/jsp-api -->
<dependency>
<groupId>javax.servlet.jsp</groupId>
@enujo
enujo / usew3.css
Last active February 20, 2017 08:02
How to use w3.js
<!-- 링크를 추가해서 사용 -->
<!DOCTYPE html>
<html>
<title>My Web</title>
<script src="https://www.w3schools.com/lib/w3.js"></script>
<!-- js파일을 다운 받아 같은 위치에서 사용 -->
<!DOCTYPE html>
@enujo
enujo / div01.jsp
Created February 22, 2017 02:06
div
<!-- Middle Column -->
<div class="w3-col m7">
<div class="w3-row-padding">
<div class="w3-col m12">
<div class="w3-card-2 w3-round w3-white">
<div class="w3-container w3-padding">
<h6 class="w3-opacity">Social Media template by w3.css</h6>
<p contenteditable="true" class="w3-border w3-padding">Status: Feeling Blue</p>
<button type="button" class="w3-btn w3-theme"><i class="fa fa-pencil"></i>  Post</button>
@enujo
enujo / AddMileage.sql
Last active February 28, 2017 01:05
mileage_cate테이블에서 값을 가져와 mileage테이블에 있는값 더하기
UPDATE
tb_person p
SET
p.person_total_mileage =
(SELECT
SUM(mct.mileage_cate_price - m.mileage_use_price)
FROM
tb_mileage m
JOIN
tb_mileage_cate mct
@enujo
enujo / w3.html
Created February 27, 2017 07:30
w3 top, tap
<!DOCTYPE html>
<html>
<title>W3.CSS Template</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://www.w3schools.com/lib/w3.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Inconsolata">
<style>
body, html {
height: 100%;
@enujo
enujo / date.html
Created March 27, 2017 08:15
javascript 날짜 계산
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
<script src="//code.jquery.com/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script type="text/javascript">
$(function() {
$('#endDate').change(function(e) {
@enujo
enujo / date.html
Created March 28, 2017 00:17
jQuery 날짜 자동 계산
<script type="text/javascript">
function addzero(n){ // 한자리가 되는 숫자에 "0"을 넣어주는 함수
return n < 10 ? "0" + n: n;
}
function dateInput(n,m){
$("#StartDate").val(""); // 우선 이미 들어가있는 값 초기화
$("#EndDate").val("");
var date = new Date();