title: AngularJS - ReferenceError: $ is not defined
body: <p>I'm getting the following error when I try to do this</p>
  
  <p><code>var fbcanvas = $('#fbcanvas');</code></p>
  
  <p>This is the error I got</p>
  
  <blockquote>
    <p>ReferenceError: $ is not defined</p>
  </blockquote>
  
  <p>This is my JS code</p>
  
  <pre><code>var feedbackModule = angular.module('feedbackModule', [ 'ui.bootstrap', 'dialogs' ]);
  
  feedbackModule.controller('feedbackDialog', function($scope, $rootScope, $timeout, $dialogs) {
  $scope.confirmed = 'You have yet to be confirmed!';
  $scope.name = '"Your name here."';
  
  $scope.sendFeedback = function() {
  
  html2canvas(document.body, {
      onrendered: function(canvas) {
      var data = canvas.toDataURL('image/png'), dlg = null;
  
      dlg = $dialogs.create('js/plugin/vzfeedbacktool.html', 'feedbackToolController', {
          imgdata: data
      }, {
          key: false,
          back: 'static'
      });
      dlg.result.then(function(name) {
          $scope.name = name;
      }, function() {
          $scope.name = 'You decided not to enter in your name, that makes me sad.';
      });
  
      }
  });
  }; // end launch
  
  });
  
  feedbackModule.controller('feedbackToolController', ['$scope', '$modalInstance', function($scope, $modalInstance, data) {
  
  $scope.cancel = function() {
  $modalInstance.dismiss('canceled');
  }; // end cancel
  
  $scope.save = function() {
  debugger;
  var fbcanvas = $('#fbcanvas');
  var ctx = fbcanvas.getContext('2d');
  var image = new Image();
  
  image.src = data.imgdata;
  ctx.drawImage(image, 0, 0);
  }; // end save
  
  }]);
  </code></pre>
  
  <p>Any idea if I'm missing something? by the way, if I try to execute that code directly in the console it works fine :S</p>
  
  <p>Thanks</p>