2. Hello AngularJS II


#1

Likewise, any new properties attached to $scope will become available to use in the view. In the controller, attach promo to $scope, and set its value to your own string.

app.controller('MainController', ['$scope', function($scope) {
$scope.Jammin = 'Top Sellers in Books';
}]);

What do I do with this??


#2

ok I have your answer right here! I had to create each other vaor of cadena with another value of command:


#3

I'm wondering the same thing Richard...
I tried this and no luck "$scope.promo = 'Promo Code'; "

Suggestions anyone?


#4

I am also stuck and would appreciate any help...?


#5

Add a new scope to the controller. This worked for me.

app.controller('MainController', ['$scope',
function($scope) {
$scope.title = 'Hello I am using Angular JS';
$scope.promo = "This is the promo scope";
}]);


#6

try moving your semi-colon to outside your quotation mark
instead of 'Promo Code;'
try
:stuck_out_tongue_winking_eye:romo Code';