Anyone has some ideas?

=D

On Wednesday, August 5, 2015 at 5:11:46 PM UTC-4, Yang Liu wrote:
>
> Hey, guys.
> I am a newbie for AngularJS and right now I want to simulate a curl 
> command in angularjs.
> This is the original curl command,
>
> *curl -XGET -s -u username:password  '###URL#######'*
>
> How can I translate above command to angularjs request?
>
> My codes right now:
>
> app.controller("xxxCtrl", function ($scope, $http) {
>     $http({url:'###URL#######',method:'get',withCredentials:true})
>     .success( function(response){
>         $scope.data = response;
>     })
>     .error( function(error){
>         $scope.data = error;
>     })
>     ;
> })
>
>
> Thank you <3 <3 <3 <3 <3
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to