프로그래밍/제이쿼리 썸네일형 리스트형 제이쿼리 한번에 여러개 삭제하기. 게시판 류의 리스트 페이지에서 한번에 여러개 삭제하기 삭제 목록에서 저렇게 주르륵 있다고 가정하고 두개를 모두 체크하고 삭제버튼 클릭하면. // 삭제하기 $("#list_del").click(function () { if(confirm("삭제하시겠습니까?")){ var select_data = []; $("[name='SEQ[]']:checked").each(function() { select_data.push($(this).val()); }); jQuery.post("/main/list_del", {"SEQ": select_data }, function (data, testStatus) { if (data == "ok") { alert("삭제되었습니다."); location.reload(); } els.. 더보기 제이쿼리로 폼 액션 및 서브밋 하기 구분을 나누어서 폼에 액션을 하려면 아래처럼 사용가능. var ajax_state = "card"; if(ajax_state == "card") { $("#regist-form").attr('action', '/order/pay_write_card'); $("#regist-form").submit(); }else if(ajax_state =="cash") { $("#regist-form").attr('action', '/order/order_write_cash'); $("#regist-form").submit(); } location.href="/main"; 더보기 제이쿼리 에이작스 사용법 $.ajax({ type: 'POST', url: '/order/worklog_order_insert', data: { memo: $("#memo").val() ,manager_name: $("#manager_name").val() }, success: function (result) { //console.log(result); if (result == "ok") { alert("저장되었습니다."); } else { ajax_state = "fail"; alert("저장되지않았습니다"); } } }); // end ajax 더보기 이전 1 2 3 4 5 6 7 ··· 12 다음