html head script language JavaScript src js jquery js script script la

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<html>
<head>
<script language="JavaScript" src="/js/jquery.js"></script>
<script language="JavaScript" src="/js/core.js"></script>
<script>
$(document).ready(function() {
$("#check").bind("click", function(event) {
$.ajax({
url: "js.php",
type: "POST",
data: ("name=" + $("#name").val()),
dataType: "text",
success: function(res) {
alert(res);
}
})
})
})
</script>
</head>
<body>
<div>
<input name="name" id="name" type="text" />
<input value="Клик" id="check" type="button" />
</div>
</body>
</html>