I have an external file being loaded via template.php using the following code:
function digital_dots_preprocess_views_view(&$vars) {
$view = $vars['view'];
if($view->name == 'work') {
drupal_add_js(drupal_get_path('theme', 'digital_dots') . '/assets/scripts/fx.js');
}
}
The JS file is being loaded with the following code:
(function ($) {
$(".image-overlay").hide();
//alert('It works!');
})( jQuery );
Un-commenting the alert will trigger the alert however the hide effect doesn't?
Very confused!