1

I need to use jquery ui tabs library but only in one add form. So i used hook_form_alter() to enable tabs and add my js:

drupal_add_library('system', 'ui.tabs');
drupal_add_js(drupal_get_path('theme', 'rating') .'/js/newad.js', 'file');

Library and script was correctly added into page head

and it is correctly available by this url but something wrong with it and it's not working:

error screensot

Wy Chrome is failed to load it?

contents of newad.js:

(function ($) {

    $(function() {
        $( ".select-format-ads" ).tabs();
    });

})(jQuery);

UPD: if i add alert('test'); in begining nothing happens in Chrome, but works fine in Safari.

Yaroslav
  • 2,338
  • 26
  • 37

1 Answers1

1

I was resolve that. Problem causes by AdBlock extension of GoogleChrome because of term "ad" in js filename.

Answer was found here in other question

So i just rename thet file an all seems work fine now.

Community
  • 1
  • 1
Yaroslav
  • 2,338
  • 26
  • 37