Skip to content

Instantly share code, notes, and snippets.

@gajus
Created October 1, 2014 13:11
Show Gist options
  • Save gajus/b7a15cbfb473293cf85c to your computer and use it in GitHub Desktop.
Save gajus/b7a15cbfb473293cf85c to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html ng-app="sportsStoreAdmin">
<head>
<title>Administration</title>
<script src="./static/js/angular.js"></script>
<script src="./static/js/ngmodules/angular-route.js"></script>
<script>
angular.module('sportsStoreAdmin', ['ngRoute'])
.config(function ($routeProvider) {
$routeProvider.when('/login', {
templateUrl: '/views/adminLogin.html'
});
$routeProvider.when('/main', {
templateUrl: '/views/adminMain.html'
});
$routeProvider.otherwise({
redirectTo: '/login'
});
});
</script>
</head>
<body>
<ng-view></ng-view>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment