I have this JS function in a layout page I’m using on a asp.net MVC website:
$(document).ready(function () {
//Display the welcome ad
if (@Globals.configSettings.DisplayWelcomeAd != false) {
displayWelcomeAd('@Utility.IsBot');
}
SocialShareKit.init();
});
And what is happening is that @Globals.configSettings.DisplayWelcomeAd is false. It’s going and checking, and returning false, yet it still runs the code block every time. Do you have any idea why it would be doing this??