JavaScript Why is my AngularJS $scope not working? angularjs scope not working,angularjs scope watch not working,angularjs

I am very very new to Angular and still very much a newbie to Javascript. I followed a tutorial, but the result is not working in my project.

Tutorial: http://toddmotto.com/ultimate-guide-to-learning-angular-js-in-one-day

HTML

<!DOCTYPE html>
<html ng-app="soCLean">
    <head></head>
    <body ng-controller="soCleanLandingPage">
        <div>
            <p>{{locale}}</p>
            <p>{{type}}</p>
            <p>{{service}}</p>
            <p>{{serviceSingle}}</p>
        </div>
        <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/angularjs/1.2.12/angular.min.js"></script>
        <script>
                var soClean = angular.module('soClean', []);
                    soClean.controller('soCleanLandingPage', ['$scope', function ($scope) {
                        $scope.locale = 'vancouver';
                        $scope.type = 'residential';
                        $scope.service = 'pressure washing';
                        $scope.serviceSingle = 'pressure wash';
                }]);
        </script>
    </body>
</html>

I have removed all extra stuff from the code sample above, but I should advise that I am also pulling two fonts and jQuery from Google CDN, and have a couple local jQuery plugins.

I am also using a few external CSS files. The page in its entirety can be found at here.

PLease help me understand what I am doing wrong and why this is not working. Thanks.

Answer:1

I append the data from a json-object to a table: var array1 = $.map(data, function (field, i) { return '<tr><td>' + field.date + '</td><td>' + field.art + '</td><...

I append the data from a json-object to a table: var array1 = $.map(data, function (field, i) { return '<tr><td>' + field.date + '</td><td>' + field.art + '</td><...

For Google Apps Script for Google Docs, in the Sidebar.html file I use this code(simplified to remove irrelevant parts): <div class="sidebar branding-below"> <form> <div class="...

For Google Apps Script for Google Docs, in the Sidebar.html file I use this code(simplified to remove irrelevant parts): <div class="sidebar branding-below"> <form> <div class="...

  1. google apps script tutorial
  2. google apps script getrange
  3. google apps script documentation
  4. google apps script sheets
  5. google apps script logger
  6. google apps script api
  7. google apps script get sheet by name
  8. google apps script for loop
  9. google apps script reference
  10. google apps script dashboard
  11. google apps script triggers
  12. google apps script web app
  13. google apps script date
  14. google apps script editor
  15. google apps script array
  16. google apps script alert
  17. google apps script send email
  18. google apps script spreadsheet
  19. google apps script global variable
  20. google apps script libraries

jsFiddle: http://jsfiddle.net/az6Ug/ Using Snap.svg library, I want drag on the SVG and get the mouse position. I need the mouse position on the internal matrix, not the browser mouse position. I ...

jsFiddle: http://jsfiddle.net/az6Ug/ Using Snap.svg library, I want drag on the SVG and get the mouse position. I need the mouse position on the internal matrix, not the browser mouse position. I ...

I am still newbie to integrate elfinder and tinymce, i already follow tutorial in elfinder wiki in form.php in tinymce init already added file_browser_callback:elFinderBrowser: tinyMCE.init({ ...

I am still newbie to integrate elfinder and tinymce, i already follow tutorial in elfinder wiki in form.php in tinymce init already added file_browser_callback:elFinderBrowser: tinyMCE.init({ ...

  1. integrate elfinder with codeigniter