0

First of all, please don't think that I asked this question before even bothering to search for the solution. I'm aware that there're lots of threads about this issue both on SO and all over the internet. But the thing is, everybody keeps saying It's because the browser object was deprecated in jquery 1.3 and removed in 1.9+. But there's no single place I refer to $.browser object in my own code. I get this Cannot read 'opera' property of undefined error inside jquery-ui (v 1.8.24) file. I've recently decided to fire a full NugGet update to my project in Visual Studio. Among them was jQuery too. Now, it seems jQuery UI was not updated in accordance with the new jQuery. What do I have to do to get rid of this problem?

EDIT: I also get this.element.propAttr error in the same file.

ADDED

this.element.propAttr $browser undefined list of juery files

5
  • If you want us to help solving your problem you have to share some code or at least the code where the specific error is taking place. A full list of plugins you are using could also help to solve this issue. Commented Oct 16, 2015 at 6:06
  • @GuyT, I've added the information you need. Please see the edit. Neither codes above are mine, they're from the jquery-ui 1.8.24 file. Commented Oct 16, 2015 at 6:13
  • Ok, I'm not familiar with all the plugins but I know how to program JavaScript so lets see what we can do and give it a shot ;) It seems that a widget 'ui.button' is created and this widget is still using the deprecated code($.browser) Are you able to determine the jQuery UI version? In their example they are using 1.11.4(api.jqueryui.com/button). The main problem, no updated jQuery UI, should be solved. Commented Oct 16, 2015 at 6:23
  • And I see you are using multiple jQuery versions. The last one loaded will be the real version. The same is also valid for the other plugins(like jquery.ui). For production I would suggest to only load the *.min versions. Commented Oct 16, 2015 at 6:30
  • Thanks, GuyT, for help and spared time. Commented Oct 16, 2015 at 6:36

1 Answer 1

1

I finally realized that this was not a problem with jquery but it was a problem with NuGet package installer not doing its job complete. When I looked inside the scripts folder, I found out that both newer-1.11.4 and older -1.8.24 presented. And as the 1.8.24 version was the last loaded one any call to jQueryUI ended up in that file which tried to reference non-existing-anymore $.browser object. I thought Nuget installer would be smart enough to remove any older files. Just removing those old files solved the problem.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.