WebSquare.net Package
Type
- engine
Property Summary
Event Summary
Method Summary
- ajax( options )
- ajax통신용 함수
- download( actionUrl , XML , sendMethod )
- 서버에서 파일을 다운로드 받는 함수
- getAllBASE64Parameter( )
- get방식으로 넘어온 전체 parameter를 Base64 Encoding방식으로 변환하여 JSON 형태로 반환합니다
- getAllParameter( )
- 전체 parameter를 JSON 형태로 반환합니다
- getBASE64Parameter( param )
- get방식으로 넘어온 parameter(param)를 Base64 Encoding방식으로 변환하여 반환합니다
- getParameter( param )
- get방식으로 넘어온 parameter를 String으로 반환합니다
Property Detail
Event Detail
Method Detail
- ajax( options )
-
ajax통신용 함수
Parameter name type required description options Object Y JSON형태 객체
options.action : ajax 요청주소 options.mode : asynchronous(default)/synchronous options.mediatype : application/x-www-form-urlencoded application/json application/xml text/xml options.method : get/post/put/delete options.requestData : 요청본문 options.timeout : ajax요청후 timeout 시간. 이시간이 초과해도 응답이 오지 않는 경우 error callback함수를 실행 options.type : xml/json. xml인 경우 success callback함수의 인자객체의 responseBody속성에 xml객체가 설정된고, json인 경우 자바스크립트 객체가 설정된다.나머지 경우는 text형식이 설정. options.beforeAjax : 요청전에 실행되는 함수로 이 함수내에서 false를 return하면 ajax요청을 하지 않는다 options.success : 요청이 성공한 경우 실행되는 callback함수 options.error : 요청이 실패한 경우 실행되는 callback함수 Samplevar options = {}; options.action = "http://localhost:8080/test.jsp"; options.mode = "asynchronous"; options.mediatype = "text/xml"; options.method = "post"; options.requestData = " "; options.success = doSucess; options.error = doError; WebSquare.net.ajax( options ); - download( actionUrl , XML , sendMethod )
-
서버에서 파일을 다운로드 받는 함수.
Parameter name type required description actionUrl String Y 파일을 다운 받기 위해서 접속해야 하는 주소 XML String Y 문자열은 xmlValue라는 이름으로 서버로 올라간다. 값을 지정하지 않은 경우(undefined인 경우) xmlValue라는 값은 제외하고 서버로 전송한다. sendMethod String Y get, post와 같은 전송 방식, 기본값은 post이다. SampleWebSquare.net.download( url, "", "post" ); - getAllBASE64Parameter( )
-
get방식으로 넘어온 전체 parameter를 Base64 Encoding방식으로 변환하여 JSON 형태로 반환합니다.SampleWebSquare.net.getAllBASE64Parameter();
- getAllParameter( )
-
전체 parameter를 JSON 형태로 반환합니다.SampleWebSquare.net.getAllParameter();
- getBASE64Parameter( param )
-
get방식으로 넘어온 parameter(param)를 Base64 Encoding방식으로 변환하여 반환합니다.
Parameter name type required description param String N 값을 가져올 uri에서 지정된 param Return type description String param 문자열 반환 SampleWebSquare.net.getBASE64Parameter("name"); - getParameter( param )
-
get방식으로 넘어온 parameter를 String으로 반환합니다.
Parameter name type required description param String N 값을 가져올 uri에서 지정된 param Return type description String param 문자열 SampleWebSquare.net.getParameter("name");