Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JS function throws is not defined error.

 
Samir Banerjee
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am facing a strange issue. I have a JS function which resides in the same JSP file from where it is being called. And this JSP file has been included at several places in my application. This JS call works fine at all places except at one place where it throws function is not defined error.
Has anyone faced any similar issue? What can be the possible reasons for this? Let me know in case of any confusions.

Thanks in advance!

Regards
 
Ashwini Kashyap
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Samir,

I think this problem might not be too big. Mostly your JSP is not getting included properly.

Please recheck the code again and you might find the root cause else paste some code here will see to it.

Thanks and Regards,
---------------------------------------------------------------------------------------
Ashwini Kashyap | akashyap@infocepts.com | www.infocepts.com
---------------------------------------------------------------------------------------
 
Samir Banerjee
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ashwini for the reply. To include I simply do -



And this also same at all places, not sure why problem occurs at only place? What else code can be helpful?

Regards
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Our crystal ball is in the shop, it is impossible to see into your application from our desks.

You need to debug, do you see the function when you view source/inspect with the debugger.

Eric
 
Ashwini Kashyap
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Samir then I suppose you are calling a function before you are including the jsp.

Please recheck.

Thanks and Regards,
---------------------------------------------------------------------------------------
Ashwini Kashyap | akashyap@infocepts.com | www.infocepts.com
---------------------------------------------------------------------------------------
 
Samir Banerjee
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Eric - True and that is why I didn't ask for any solution from anyone, I just wanted to know the possible reasons if anyone has faced similar kind of issue.

@Ashiwini - Thanks will try to fix it and reply to this thread once done.

Regards
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic