에 제출하지 않습니다. 내 html 코드의 제출 버튼이 onclick 이벤트에 응답하지 않습니다. . 제 html 코드를 살펴보고 내가 잘못 된 위치를 알려주십시오. 위치를 사용하고 있습니다 .href 보통, 그러나, 그것도 doesnt는 여기에서 일한다. 라디오 버튼 옵션 "yes"또는 "no"에 따라 2 개의 URL 사이를 전환하는 기능을 사용했습니다.HTML 제출 버튼은 해당 URL의
미리 감사드립니다. 이 유형의 입력 제출해야하고 당신이 그것을 클릭하면
<html>
<head>
<style type="text/css">
body{
font-family:"Lucida Grande", "Lucida Sans Unicode", Verdana, Arial, Helvetica, sans-serif;
font-size:12px;
}
p, h1, form, button{border:0; margin:0; padding:0;}
.spacer{clear:both; height:1px;}
/* ----------- My Form ----------- */
.myform{
margin:0 auto;
width:400px;
padding:10px;
}
/* ----------- stylized ----------- */
#stylized{
border:solid 2px #000000;
background:#ebf4fb;
width:500px;
height:350px;
}
#stylized h1 {
font-size:14px;
font-weight:bold;
margin-bottom:8px;
}
#stylized label{
display:block;
font-weight:bold;
text-align:left;
width:140px;
float:left;
}
#stylized form{
float:left;
font-size:12px;
<!--padding:4px 2px;-->
<!-- border:solid 1px #aacfe4;-->
width:100px;
margin:2px 0 20px 10px;
}
#stylized table, th, td
{
font-size:12px;
width:400px;
border: 1px solid black;
}
th
{
width:10%;
background-color: black;
color: white;
}
#stylized button.custom-submit {
float: left;
clear: none;
margin-left: 50px;
}
</style>
<script>
$(function(){
$('myform').submit(function(event){
event.preventDefault();
window.location = $('input[type=radio]:checked').val();
});
});
</script>
</head>
<body>
<div id="stylized" class="myform">
<form id="form" name="form">
<label>New Data set :
</label>
<input type="radio" name="url" value="Inputs1.html" /> Yes
<input type="radio" name="url" value="ResultsPage.html" /> No
<br>
<label>Dataset description:
</label>
<input type ="text" name= "Dataset" size="30"><br><br><br>
<table id="Previous Datasets">
<tr>
<th>Check</th>
<th>Token Number</th>
<th>Dataset description</th>
</tr>
<tr>
<td><input type="checkbox"> </td>
<td>234567</td>
<td>MHEX North America Dataset</td>
</tr>
<tr>
<td><input type="checkbox"> </td>
<td></td>
<td></td>
</tr>
<tr>
<td><input type="checkbox"> <td>
<td></td>
</tr>
<tr>
<td><input type="checkbox"> </td>
<td></td>
<td></td>
</tr>
<tr>
<td><input type="checkbox"> </td>
<td></td>
<td></td>
</tr>
</table>
<div style="text-align: center"><br>
<input type="Submit" name="submit" value="Submit" class="submit" onClick="gotoResults()">
<div class="spacer"></div>
</form>
</div>
</body>
여기에만 관련 정보를 표시하도록 게시물을 수정하십시오 : 당신의 제출 HTML 및 귀하의 JS에서 – Bigood
U 버튼 클릭에서 메서드를 호출했지만 정의가 없습니다. – Sasidharan
$ ('입력 : 드롭 다운 메뉴') 란 무엇입니까? – VahidNaderi