<%@ page contentType="text/html; charset=EUC-KR" pageEncoding="EUC-KR"%>

<%@ page isELIgnored="false"%>
<%//무시하겠다. %>
<%  request.setCharacterEncoding("EUC-KR"); %>

<p>수식계산하기</p>
\${2+5}=${2+5}<br/>
계산=${2+5}<br/>
<p>헤더정보 얻기</p>
웹브라우저${header["user-agent"]}<br/>
사용자컴퓨터${header["host"]}<br/>

<p> 파라메터값 얻기 </p>
name : ${param["name"]}<br/>
name값 공백 여부 ${empty param["name"]}<br/> 

<p>세션&쿠키값 얻기</p>
세션ID : ${cookie["JSESSIONID"].value}<br/>

-- http://localhost/myapp/EL/hello_el.jsp?name=aaa
-- 결과 사진

 

----- JSTL

--- jar 파일을 톰캣의 저장 요청및 응답

jstl.jar

standard.jar



<%@taglib prefix="c" uri="http://java.sun.com/jstl/core"%>
<%@taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt"%>
<%@taglib prefix="sql" uri="http://java.sun.com/jstl/sql"%>
<%@taglib prefix="xml" uri="http://java.sun.com/jstl/xml"%> 


--- 파일

contact3.html

contact3.jsp

contact4.html


-- 결과





----- iftag 

<%@ page contentType="text/html; charset=EUC-KR" pageEncoding="EUC-KR"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<html><Head><Title>ggg</Title></Head> 
<body>
<center>
<c:if test="${!empty param.name }">
이름 :${param.name} 
</c:if>
</center>
</body>
</html>

-- 후에 
http://localhost/myapp/EL/iftag.jsp?name=aaa 수정
 
-- 사진






 














[출처] Java 메일 서버(james) 설치 및 환경 구축 |작성자 zino  

http://blog.naver.com/zino1187/110026018352 퍼왔어요   

----------------------------------------------------

1단계 : 메일 서버 다운로드

----------------------------------------------------

자바의 메일서버는 아파치에서 제공하는 james(Java Apache Mail Enterprise Server) 서버를 이용할 수 있다

서버 다운로드 ==> http://james.apache.org

 

----------------------------------------------------

2단계 : 메일 서버 설치

----------------------------------------------------

설치방법은 간단하다,

다운로드 받은 파일의 압축을 풀면되는데, 주의 할점은 바탕화면에 압축을 풀면 가동되지 않는다.

필자의 경우 C:\james-2.3.1 에 위치 시켰다.

 

----------------------------------------------------

3단계 : 메일 서버 환경 설정

----------------------------------------------------

james 서버의 환경설정은 config.xml 파일로 제어한다.

파일의 경로는 /app/james/SAR-INF 에 있다.

config.xml 을 연후 다음과 같이 수정해준다.

1.사용자의 암호 지정 (설정이 끝나면 이 암호로 서버에 접속할 것이다.)

  <account login="root" password="내 암호"/> 

 

2.메일서버 지정하기

  servername 태그안에 자신의 아이피 혹은 호스트명을 적는다.

  <servername>127.0.0.1</servername>

 

3.DNS서버 지정하기

  ipconfig로 자신의 DNS서버를 찾아서 다음과 같이 기재한다.

   <dnsserver>
      <servers>
          <server>DNS서버 주소</server>
      </servers>
      <autodiscover>true</autodiscover>
      <authoritative>false</authoritative>

      <maxcachesize>50000</maxcachesize>
   </dnsserver>

------------------------------------------------------------

4단계: james 서버 실행 및 접속하기

------------------------------------------------------------

/bin/ 디렉토리의 run.bat 파일을 실행시킨다.

이로써 모든 설정을 다 마쳤다.

 

 

------------------------------------------------------------

james 서버 접속 및 관리

------------------------------------------------------------

1단계 : 커맨드창에서 (cmd) 다음과 같이 명령어를 입력하여 텔넷으로 서버에 접속해 보자

C:/> telnet   localhost  4555

 

2단계 :  root계정으로 로그인 한다.

아이디 - root,

패스워드-  config.xml 에서 지정한 비밀번호

 

3단계 : help 라고 입력하여 명령어 정보를 확인한다.


+ Recent posts