Binded the Enter key to a form submission on the landing page.

This commit is contained in:
Maxim Khlobystov 2014-10-30 13:24:08 -07:00
parent 91ad8d560b
commit ebe8f0d851

View File

@ -1,23 +1,21 @@
<!doctype html>
<html ng-app="landingPage">
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.4/angular.min.js"></script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script src="../public/js/app.js"></script>
</head>
<body>
<div>
<label>Username:</label>
<input type="text" ng-model="username" placeholder="Enter a name here">
<label>Meeting name:</label>
<input type="text" ng-model="meetingName" placeholder="Enter a meeting name">
<label>(e.x. Demo Meeting)</label>
</div>
<div ng-controller="MainCtrl">
<form ng-submit="postUsername()">
<input type="submit" value="Send"> <br /><br />
</form>
</div>
</body>
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.4/angular.min.js"></script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script src="../public/js/app.js"></script>
</head>
<body>
<div ng-controller="MainCtrl">
<form ng-submit="postUsername()">
<label>Username:</label>
<input type="text" ng-model="username" placeholder="Enter a name here">
<label>Meeting name:</label>
<input type="text" ng-model="meetingName" placeholder="Enter a meeting name">
<label>(e.x. Demo Meeting)</label><br/>
<input type="submit" value="Send"><br/><br/>
</form>
</div>
</body>
</html>