You should use ngRoute.By the courtesy of "ngRoute" you can redirect user to specific views by the specific urls. Pls make some research about it. Let's assume you solve your view and redirect issues. How you gonna fetch data from server side? At this time I suggest you to look at service and factory objects.
Hope it helps.
Sample code :
// create the module and name it exApp
// also include ngRoute for all our routing needs
var exApp= angular.module('exApp', ['ngRoute']);
// configure our routes
exApp.config(function($routeProvider) {
$routeProvider
// route for the home page
.when('/', {
templateUrl : 'pages/home.html',
controller : 'mainController'
})
// route for the about page
.when('/about', {
templateUrl : 'pages/about.html',
controller : 'aboutController'
})
// route for the contact page
.when('/contact', {
templateUrl : 'pages/contact.html',
controller : 'contactController'
});
});
// create the controller and inject Angular's $scope
exApp.controller('mainController', function($scope) {
// create a message to display in our view
$scope.message = 'Everyone come and see how good I look!';
});
exApp.controller('aboutController', function($scope) {
$scope.message = 'Look! I am an about page.';
});
exApp.controller('contactController', function($scope) {
$scope.message = 'Contact us! JK. This is just a demo.';
});