Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Uncaught TypeError: Cannot set property 'mobile' of undefined

I am developing an app with angular js and phonegap.

I am using jquery mobile in a directive, it is for adding some animation to a notification bar. I t works well with jquery 1.8.1 but when I use jquery mobile

<script src="scripts/vendor/jquery/jquery.mobile-1.3.1.js"></script>

I get the following error:

Uncaught TypeError: Cannot set property 'mobile' of undefined jquery.mobile-1.3.1.js:26

(anonymous function) jquery.mobile-1.3.1.js:26
(anonymous function) jquery.mobile-1.3.1.js:27
(anonymous function) jquery.mobile-1.3.1.js:22
(anonymous function) jquery.mobile-1.3.1.js:24

enter image description here

Any suggestions?

Thanks in advance!

like image 457
Arcayne Avatar asked Apr 24 '13 08:04

Arcayne


2 Answers

With jQuery-Mobile version 1.3.1, use jQuery version 1.8.3 or higher. It's recommended to use jQuery version 1.9.1.

like image 186
Omar Avatar answered Nov 06 '22 15:11

Omar


@Omar actually you made me fix that by your comment, I left commented out:

<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>

Thanks!

like image 6
Arcayne Avatar answered Nov 06 '22 13:11

Arcayne