Speed up development with full-stack environments for every branch.

Learn More

AngularJS NodeJs get request -vishwas [express, Node.js and Angular.js]

Forked from AngularJS NodeJs Basic Example for post request -vishwas.

7 Runs 16 Views 3 Copies


vishwas 2

published 3 months ago

    angular.module('myApp').controller('AppCtrl', function($scope,$http) {
      $scope.message = 'Hello World from client'; 
       $scope.click = function(message)
        .then(function(response) {
            //First function handles success
             $scope.message = 'sucess from server'+response.data.message
        }, function(response) {
            //Second function handles error
             $scope.message = 'Failure from server ! Bro please check it out'
    Please login/signup to get access to the terminal.

    Your session has timed out.

    Dismiss (the page may not function properly).