Month: November 2015

Difference between {{}} and ng-bind in AngularJS

November 12, 2015

To bind our data to the HTML page, Angular gives the ability to use {{}} known as double curly brackets or ng-bind.Both ways are performing the same functionality. {{}} Example:-       name is JS object or some variable we are referring to. It makes your template very readable i.e Anyone going through a code […]

Read More

XMLHttpRequest Cannot Load error in AngularJS

November 10, 2015

Error:- XMLhttpRequest Cannot load ? How to handle this error.  Browser Error Solution:- This is common error when you attempt to open load files directly in chrome.Reason,Chrome and other browsers have imposed security restrictions for “Cross Origin Requests“, which means that you cannot load the files directly from your local hard-disk to browser hence […]

Read More

Conditional display of elements/data using Angular Js Directives.

November 2, 2015

Today we would learn frequently used Angular JS directives. Problem:- How to achieve conditional construct in Angular js? Solution:- We would achieve it by using built in directives of Angular JS. 1. ng-Switch:-We can control the conditional display of data. It is similar to Switch-Case in JavaScript. JavaScript syntax:-Switch(expression) { Case n: Code Break; Case […]

Read More