In HTML I have this line of code:
<input type=text class=training-comment placeholder=Enter comment ng-model=content data-ui-keypress={13:'keypressCallback($event)'}>
And in controller this:
$scope.keypressCallback = function ($event) {
console.log(comment is, $scope.content);
$event.preventDefault();
};
And when I enter some text in input and press enter in console I see that $scope.content is undefined.
Why is this ?