<form role="form" class="search-form" method="post">
<div class="form-group">
<input type="text" class="form-control" id="search" placeholder="Get our prices. Enter your email">
<button onclick="fnNext()" class="btn btn-theme" type="button">
Submit <i class="fa fa-chevron-right"></i>
</button>
<script>
function fnNext() {
window.location.replace("http://localhost:5489/Quote/BondInfo");
}
</script>
<br />
<label style="color:white;" >Your Information is safe & secure</label>
</div>
</form>
ASKER
$('#gotoNext').click(function() {
var email = $('#search').val();
var url = 'http://localhost:5489/Quote/BondInfo?search=' + email;
localStorage.setItem('emailAddress', email);
window.location.replace(encodeURI(url));
});
ASKER
JavaScript is a dynamic, object-based language commonly used for client-side scripting in web browsers. Recently, server side JavaScript frameworks have also emerged. JavaScript runs on nearly every operating system and in almost every mainstream web browser.
TRUSTED BY
//HTML
Open in new window
//JqueryOpen in new window
If you want to carry on with your raw Javascript, then you can get the search value with a call to getElementById.