Files
cypress/system-tests/projects/e2e/forms.html
Jessica Sachs a045e4f59a chore: move server e2e tests to system-tests (#16354)
Co-authored-by: Brian Mann <brian.mann86@gmail.com>
Co-authored-by: Zach Bloomquist <git@chary.us>
Co-authored-by: Zach Bloomquist <github@chary.us>
2021-10-18 19:53:14 +00:00

32 lines
730 B
HTML

<!DOCTYPE html>
<html>
<head>
<title></title>
<script type="text/javascript" src="static/jquery.js"></script>
</head>
<body style="background-color: #ddd;">
<script type="text/javascript">
$(function(){
$("form").submit(function(e){
var form = $(this)
setTimeout(function(){
$.post("/users", form.serialize()).done(function(data){
var span = $("<span><strong>form success!</strong></span>")
span.append(JSON.stringify(data))
form.append(span)
})
}, 500)
return false
})
})
</script>
<form>
What is your name?
<input name="name">
<button id="submit" type="submit">submit</button>
</form>
</body>