I'm trying to add bar-header and form-input. But the username form doesn't appear, probably because it's overlapping with the bar-header. I've added class="has-header" in ion-content but this doesn't work and the username form and the bar-header still overlap eachother. Can anyone help me out?
This is my code:
<!DOCTYPE html>
<html ng-app="myApp">
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<title></title>
<link href="lib/ionic/css/ionic.css" rel="stylesheet">
<link href="css/style.css" rel="stylesheet">
<!-- IF using Sass (run gulp sass first), then uncomment below and remove the CSS includes above
<link href="css/ionic.app.css" rel="stylesheet">
-->
<!-- ionic/angularjs js -->
<script src="lib/ionic/js/ionic.bundle.js"></script>
<!-- cordova script (this will be a 404 during development) -->
<script src="cordova.js"></script>
<!-- your app's js -->
<script src="js/app.js"></script>
<script src="js/controllers.js"></script>
<script src="js/services.js"></script>
</head>
<body>
<div class="bar bar-header bar-calm">
<h1 class="title">bar-calm</h1>
</div>
<ion-content class="has-header">
<div class="list">
<label class="item item-input">
<span class="input-label">Username</span>
<input type="text">
</label>
<label class="item item-input">
<span class="input-label">Password</span>
<input type="password">
</label>
<label class="item item-input">
<span class="input-label">Username</span>
<input type="text">
</label>
<label class="item item-input">
<span class="input-label">Password</span>
<input type="password">
</label>
</div>
</ion-content>
<div class="bar bar-footer bar-calm">
<div class="title">Footer</div>
</div>`enter code here`
</body>
</html>
The problem is that you don't create angular app itself.
just add an empty app:
angular.module('myApp', ['ionic'])
.controller('MapCtrl', function($scope) {
});