You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The side effect is that these scripts are not loaded at all. If this JS code is pasted into the console, then the $.ageCheck script works just fine. Also, these scripts are not present in the HTML code at all, meaning they never got loaded.
Trying to debug this, I found that plugin_dir_url( __FILE__ ) . 'js/dispensary-age-verification-public.js' does produce the correct path, so I'm not sure if there is a filter removing these somewhere else? The site I'm debugging for this problem is extremely complex so not sure what other features may be involved.
Was able to temporarily get around this using the following hack solution in another function:
Similar problem to the one reported by another user
TypeError: $.ageCheck is not a function
:Was able to trace the problem to these lines:
The side effect is that these scripts are not loaded at all. If this JS code is pasted into the console, then the
$.ageCheck
script works just fine. Also, these scripts are not present in the HTML code at all, meaning they never got loaded.Trying to debug this, I found that
plugin_dir_url( __FILE__ ) . 'js/dispensary-age-verification-public.js'
does produce the correct path, so I'm not sure if there is a filter removing these somewhere else? The site I'm debugging for this problem is extremely complex so not sure what other features may be involved.Was able to temporarily get around this using the following hack solution in another function:
Any idea why this could be failing or how to fix it?
The text was updated successfully, but these errors were encountered: