Click here to Skip to main content
15,921,959 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more: (untagged)
how can I put the response of http get in a log file in angularjs .

JavaScript
s.getCodList= function(document) {
    $http({
        "method" : "GET",
        "url" : s.appName + '/secure/getFile?fileName=CodeList.json'
    }).then(function(data) {

        if (data) {
            s.codList = data.data.eventCodeList.codList;
            s.displayConsent(document);
        }
    }).error(function() {
        s.initFunctions();
        s.consentCodeListError = true;
    });
}


What I have tried:

I tried to use $log and Stacktrace in angular but the result appears in the console . I want to write the output in the log file of the server tomcat (logs)
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900