javascript make function globally available code example
Example 1: access method globally js
window.checkCookie = function(){
// do whatever you want here
};
Example 2: making js local function globally accessible
window.checkCookie=function(){
// do whatever you want here
};