Skip to content Skip to sidebar Skip to footer

Encodeuricomponent In Angularjs $http Service

I am new to AngularJS and trying to learn the ropes. I'm using the following line of code (untested mind you) to send an item of information to a server method that will then send

Solution 1:

You don't need to encode the properties, $http does: https://github.com/angular/angular.js/blob/master/src/ng/http.js#L758

As to the way of doing it.. This looks fine. You can switch to $resource if have an object that needs a couple of REST things on the server, but $http works fine in simple situations.

Post a Comment for "Encodeuricomponent In Angularjs $http Service"