<div class="codetitle"> <span><a style="CURSOR: pointer" data="33773" class="copybut" id="copybut33773" onclick="doCopy('code33773')"><u>코드 복사</u></a></span> 코드는 다음과 같습니다.</div> <div class="codebody" id="code33773"> <br>function checkPhoto(fnUpload) <br>{ <br> var filename = fnUpload.value; <br>alert(filename); <br>var mime = filename.toLowerCase().substr(filename.lastIndexOf(".")) <br>if(mime!=".jpg ") <br>{ <br>alert("사진 업로드를 위해 jpg 형식을 선택하세요."); <br>fnUpload.outerHTML=fnUpload.outerHTML; <br>} <br>} <br> </div>