Join the Stack Overflow Community
Stack Overflow is a community of 6.8 million programmers, just like you, helping each other.
Join them; it only takes a minute:
Sign up

I have a submitDetails function inside controller in app.js file and I want to call it from a javascript function. But its throwing error Error: Submit Details is undefined

clickApply: function(e) {
            
            console.log("hi&hello");
            
                    angular.element('#span').scope().submitDetails();
               
            this.hide();
            this.element.trigger('apply.daterangepicker', this);

        }

$rootScope.submitDetails=function()

share
    
can you pls elaborate pls add html and js code in a working format – Samuel J Mathew 13 mins ago
    
See This: stackoverflow.com/questions/16709373/… – Jenny 13 mins ago

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.