<html>
<head>
<title>PHP AJAX Image Upload</title>
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function (e) {
	$("#uploadForm").on('submit',(function(e) {
		var email_id = document.getElementById('email_id').value;
		var password = document.getElementById('password').value;
		var formData = new FormData();
		formData.append("email_id", email_id);
		formData.append("password", password);
		alert(email_id);
		alert(password);
		alert(formData);
		e.preventDefault();
	}));
});
</script>
</head>
<body>
<form id="uploadForm"  method="post">
<label>Enter Text:</label><br/>
<input name="email_id"  id="email_id" />
<input name="password"  id="password" />
<input type="submit" value="submit" class="btnSubmit" />
</form>
<p>Suggestions: <span id="txtHint"></span></p>
</body>
</html>