Yii Framework Forum: jQuery Problems - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

jQuery Problems on whole production site

#1 User is offline   wpler 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 14
  • Joined: 25-May 15
  • Location:Mallorca / Spain

  Posted 07 November 2017 - 08:47 AM

Hello,

i have a curious problem with my yii2 software. I use on different sites kartik select2 widget oder kartik gridview. On my local machine all works fine. But on the production machine i got always javascript / jquery errors like this:

jQuery.Deferred exception: $(...).find(...).size is not a function TypeError: $(...).find(...).size is not a function


or

Uncaught TypeError: $(...).find(...).size is not a function


On both machines i have doing composer update without errors. What can i do?
0

#2 User is offline   jacmoe 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 3,694
  • Joined: 10-October 10
  • Location:Denmark

Posted 07 November 2017 - 08:54 AM

If you are running Composer on the prod machine, perhaps you forgot to install the Composer asset plugin (globally)?
Check the installation instructions for Yii 2 one more time. :)
"Less noise - more signal"
0

#3 User is offline   Maurizio Domba Cerin 

  • Yii - Yesss It Is !!!
  • Yii
  • Group: Yii Dev Team
  • Posts: 4,543
  • Joined: 12-October 09
  • Location:Croatia

Posted 07 November 2017 - 09:22 AM

it's possible you have a newer version of jQuery on production... size() was deprecated in 1.8 and removed in 3.0 - http://api.jquery.com/size/
Find more about me.... btw. Do you know your WAN IP?
1

#4 User is offline   wpler 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 14
  • Joined: 25-May 15
  • Location:Mallorca / Spain

Posted 08 November 2017 - 03:41 AM

View PostMaurizio Domba Cerin, on 07 November 2017 - 09:22 AM, said:

it's possible you have a newer version of jQuery on production... size() was deprecated in 1.8 and removed in 3.0 - http://api.jquery.com/size/


You are right, another old jquery-declaration was inside the asset.

Thanks for help.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users