`
robinsoncrusoe
  • 浏览: 736473 次
  • 性别: Icon_minigender_2
  • 来自: 深圳
社区版块
存档分类
最新评论

JSP关于单选按钮和页面跳转的问题

    博客分类:
  • JAVA
阅读更多
<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Jsp Practice</title>
</head>
<script type="text/javascript" language="javascript">
function jump(){
	var value=document.getElementById("aa").value;
	if(value=="a"){
		window.location.href="success.jsp";
		
	}else{
		window.locatiion.href="failure.jsp";
	}
}

</script>
<body>

<input type="radio" id="aa" name="as" value="a" />

<input type="submit" id="cc" value="提交" onclick="jump();">


</body>
</html>

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics