난 폼을 가지고 있고 그걸 처리하고 3 액션을하는 JS 함수가있다. 내 기능은 다음과 같습니다.JS를 사용하여 여러 양식 작업이 작동하지 않습니까?
function submit(){
document.optin.action = "link1.php"
document.optin.target = "_self";
document.optin.submit();
window.open('http://link2.html','','scrollbars=yes,height=600,width=900,resizable=yes');
document.optin.action = "link3.php"
document.optin.target = "_self";
document.optin.submit();
}
두 번째 및 세 번째 동작은 작동하지만 첫 번째 동작은 작동하지 않습니다. 동작 1과 3은 동일한 창에서 열리고 후자는 전자보다 우선합니다. 내 코드가 뭐가 잘못 되었는가? pls ...
2 개의 동작 만 표시됩니다. 0o – elias
표시되지 않는 동작은 새 창에서 요청을받습니다. – fmsf