angularjs - Why does my routing not work in Angular JS for URL? -


i use next configuration routing:

.config(['$routeprovider',             function($routeprovider) {                 $routeprovider                     .when('/appointments', {                         controller: 'appointmentcontroller'                     })     }]) 

and controller:

.controller('appointmentcontroller', ['$scope', '$http', '$sce', function ($scope, $http, $sce) {      alert('test') }]); 

url looks as: http://blogapp.com/appointments

so, have not error on page, alert() not work when enter url

try going

http://blogapp.com/#/appointments 

the hash included default angular.


Comments

Popular posts from this blog

Java 3D LWJGL collision -

spring - SubProtocolWebSocketHandler - No handlers -

methods - python can't use function in submodule -