  function proc(mode) {
	if (!document.form.submitChk.value) {
      var imgInfo = document.form.imgInfo.value;
      if (imgInfo!="" && imgInfo!=null) window.open(path + '../include/html/bbs_addImg.htm?mode=' + mode + '&action=delImg&target=' + imgInfo,'Hfrm');
    }
  }


  
  function rewrite() {
    document.form.reset();
    init();
  }

  function CheckStr(strOriginal, strFind, strChange){ 
    var position, strOri_Length; 
    position = strOriginal.indexOf(strFind);  

    while (position != -1){ 
      strOriginal = strOriginal.replace(strFind, strChange); 
      position = strOriginal.indexOf(strFind); 
    } 

    strOri_Length = strOriginal.length; 
    return strOri_Length; 
  } 

  var rowIndex = 1;
  function addFile(form,k){
    if(rowIndex > (5-k)) return false;
    var oCurrentRow,oCurrentCell;
    var sAddingHtml;
  
    oCurrentRow = insertTable.insertRow();
    rowIndex = oCurrentRow.rowIndex;
    oCurrentCell = oCurrentRow.insertCell();
    rowIndex++;
    oCurrentCell.innerHTML = "<tr><td colspan=4><INPUT class=input TYPE=FILE NAME='filename" +rowIndex + "' size=25></td></tr>";
    form.rowCount.value = rowIndex;
  }
  
  //Ã·ºÎÆÄÀÏ »èÁ¦
  function deleteFile(form){
    if(rowIndex<2){
      return false;
    }else{
      form.rowCount.value = form.rowCount.value - 1;
      rowIndex--;
      insertTable.deleteRow(rowIndex);
    }
  }
  
  function deleteAddFile(str,fn){
    if (confirm("»èÁ¦ÇÏ½Ã°Ú½À´Ï±î?")){
      document.deleteForm.tbidx.value = str;
      document.deleteForm.filename.value = fn;
      document.deleteForm.action="/servlet/KBoardAction";
      document.deleteForm.submit();
    }
  }
