12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet type="text/css" href="../../../com/commonweb/css/common.css" ?>
- <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
- <xhtml:head>
- <xhtml:title>Untitle</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <input01/>
- <input02/>
- <input03/>
- <input04/>
- <input05/>
- <input06/>
- </main>
- </root>
- </instance>
- </model>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- </xhtml:head>
- <xhtml:body>
- <input id="input1" ref="/root/main/input01" imemode="disabled" format="999-999" style="left:120px; top:60px; width:100px; height:19px; "/>
- <caption id="caption3" class="tit_1" style="left:0px; top:0px; width:422px; height:14px; vertical-align:middle; ">format</caption>
- <caption id="caption2" class="cell_1" style="left:20px; top:60px; width:72px; height:20px; font-weight:bold; ">우편번호</caption>
- <caption id="caption4" style="left:250px; top:60px; width:130px; height:20px; ">input@foramt="999-999"</caption>
- <caption id="caption5" class="cell_1" style="left:20px; top:120px; width:72px; height:20px; font-weight:bold; ">주민번호</caption>
- <caption id="caption6" style="left:250px; top:120px; width:172px; height:20px; ">input@foramt="999999-9999999"</caption>
- <input id="input2" ref="/root/main/input02" imemode="disabled" format="999999-9999999" style="left:120px; top:120px; width:100px; height:19px; "/>
- <line id="line1" style="x1:20px; y1:95px; x2:420px; y2:95px; "/>
- <line id="line2" style="x1:20px; y1:160px; x2:420px; y2:160px; "/>
- <caption id="caption1" class="cell_1" style="left:20px; top:180px; width:72px; height:20px; font-weight:bold; ">금 액</caption>
- <line id="line4" style="x1:20px; y1:235px; x2:420px; y2:235px; "/>
- <caption id="caption7" style="left:250px; top:180px; width:172px; height:20px; ">input@foramt="#'###"</caption>
- <input id="input3" ref="/root/main/input03" imemode="disabled" format="#,###" style="left:120px; top:180px; width:100px; height:19px; "/>
- <caption id="caption9" class="cell_1" style="left:20px; top:290px; width:72px; height:20px; font-weight:bold; ">전화번호</caption>
- <input id="input4" ref="/root/main/input04" imemode="disabled" style="left:120px; top:290px; width:100px; height:19px; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var pattern = /^0\d{1,2}\-\d{3,4}\-\d{4}$/ig;
- var inputValue = model.getValue("/root/main/input04");
- if( pattern.exec(inputValue) == null ) {
- messageBox("전화번호 형식이", "E004");
- var ctrlID = event.target;
- var crtlObj = document.controls.item(ctrlID);
- crtlObj.value = "";
- model.setFocus(ctrlID);
- }
- ]]>
- </script>
- </input>
- <caption id="caption10" style="left:250px; top:290px; width:184px; height:20px; ">0\d{2,3}\-\d{3,4}\-\d{4}</caption>
- <line id="line5" style="x1:20px; y1:330px; x2:420px; y2:330px; "/>
- <caption id="caption11" style="left:20px; top:245px; width:480px; height:20px; font-weight:bold; ">* 아래와 같이 자릿수가 정해지지 않은 입력형식에는 정규식을 이용합니다.</caption>
- <caption id="caption12" style="left:250px; top:350px; width:192px; height:20px; ">01[016789]\-\d{3,4}\-\d{4}</caption>
- <input id="input5" ref="/root/main/input05" imemode="disabled" style="left:120px; top:350px; width:100px; height:19px; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var pattern = /^01[016789]\-\d{3,4}\-\d{4}$/ig;
- var inputValue = model.getValue("/root/main/input05");
- if( pattern.exec(inputValue) == null ) {
- messageBox("후대폰번호 형식이", "E004");
- var ctrlID = event.target;
- var crtlObj = document.controls.item(ctrlID);
- crtlObj.value = "";
- model.setFocus(ctrlID);
- }
- ]]>
- </script>
- </input>
- <line id="line3" style="x1:20px; y1:390px; x2:420px; y2:390px; "/>
- <caption id="caption13" class="cell_1" style="left:20px; top:350px; width:72px; height:20px; font-weight:bold; ">휴대폰번호</caption>
- <input id="input6" imemode="disabled" format="yyyy-mm-dd hh:nn:ss" style="left:165px; top:400px; width:175px; height:19px; "/>
- <caption id="caption8" class="tit_2" style="left:25px; top:30px; width:405px; height:13px; ">날짜, 숫자 포맷 적용시 imemode="disabled" 함께 적용 해야 함</caption>
- <caption id="caption14" class="cell_1" style="left:20px; top:400px; width:139px; height:20px; ">yyyy-mm-dd hh:nn:ss</caption>
- <input id="input7" maxlength="4.2" format="#,###.00" style="left:630px; top:60px; width:100px; height:19px; "/>
- <caption id="caption15" class="cell_1" style="left:480px; top:60px; width:141px; height:20px; ">소수점 2자리까지만 입력</caption>
- <caption id="caption16" class="tit_2" style="left:475px; top:35px; width:342px; height:14px; ">'0' 표기는 포맷 적용시 maxlength를 함께 적용해야 함</caption>
- <line id="line6" style="x1:20px; y1:435px; x2:420px; y2:435px; "/>
- <caption id="caption17" style="left:250px; top:205px; width:172px; height:20px; ">input@foramt="(-)#'###"(음수)</caption>
- <input id="input8" ref="/root/main/input06" imemode="disabled" format="(-)#,###" style="left:120px; top:205px; width:100px; height:19px; "/>
- <input id="input9" format="999999" style="left:440px; top:120px; width:100px; height:19px; "/>
- <input id="input10" autonext="false" format="9999999" style="left:550px; top:120px; width:100px; height:19px; "/>
- </xhtml:body>
- </xhtml:html>
|