Active_Admin Delete does not work - Uncaught TypeError: Cannot read the 'mozilla' property from undefined

I recently upgraded to the newest version of the active administrator, and now my delete buttons do not work. I use standard pages that are generated unchanged. I get this error in the browser debugging console:

Uncaught TypeError: cannot read the mozilla property from undefined active_admin.js: 9612 (anonymous function) active_admin.js: 9612 (anonymous function) active_admin.js: 10118

Here is my application.js file.

// This is a manifest file that'll be compiled into including all the files listed below. // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically // be included in the compiled file accessible from http://example.com/assets/application.js // It not advisable to add code directly here, but if you do, it'll appear at the bottom of the // the compiled file. // //= require jquery //= require underscore 

I use jquery through my site, so I'm sure that it is included.

I used rails to generate active_admin: assets many times. I am trying to fix this in about 10 hours, and I'm at a standstill. Any help would be greatly appreciated.

+6
source share
2 answers

Add below to your HTML code after loading jQuery js library: (occurs when using jQuery version 1.9 and +)

  <script src="http://code.jquery.com/jquery-migrate-1.2.1.js"></script> 
+23
source

It may be a bit late in the game, but this usually happens when you use jQuery about 1.9 or more. JQuery 1.9 and higher (I think it was at that time) pulled out the browser, sniffing so that this error came from.

+2
source

All Articles