Jquery& java脚本跨浏览器implment [英] Jquery & java script cross browser implment

查看:133
本文介绍了Jquery& java脚本跨浏览器implment的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我读到了关于jquery和JavaScript的问题,我问自己下一个问题:

jquery是什么让它成为跨浏览器而java脚本不是?



有人可以向我解释是什么让Jquery成为跨浏览器语言以及为什么JavaScript不是?



这意味着我应该在所有浏览器中支持使用jquery编写的每个代码吗?包括Internet Explorer 6-7-8?



包括所有Jquery插件?

请解释。

I read about jquery and JavaScript and I was asking my self the next question:
What is it about jquery that turns it to be a cross browser while java-script is not?

Can someone please explain to me what turns Jquery to be cross browser language and why JavaScript isn''t?

It means that every code that i write with jquery should be supported in all browsers? including internet explorer 6-7-8?

Include all Jquery plugins?
Please explain.

推荐答案

首先,jquery不是一种语言。 Jquery是一个javascript库,旨在缓解你的生活 - 所以你不必处理跨浏览器问题。

编写jquery的人写了javascript代码来处理浏览器之间的差异。但即便是jquery也不应该支持最古老的版本......但确实如此。点击此处: http://jquery.com/browser-support/?rdfrom=http%3A%2F%2Fdocs.jquery.com%2Fmw%2Findex.php%3Ftitle%3DBrowser_Compatibility%26redirect%3Dno [ ^ ]

请注意,并非所有插件都使用与主流相同的预防措施。
First of all, jquery is not a language. Jquery is a javascript library, meant to ease your life - so you don''t have to deal with things like cross-browser issues.
The people writing jquery wrote javascript code that handles the differences between browsers. But even jquery isn''t supposed to support oldest versions... but it does. Check here: http://jquery.com/browser-support/?rdfrom=http%3A%2F%2Fdocs.jquery.com%2Fmw%2Findex.php%3Ftitle%3DBrowser_Compatibility%26redirect%3Dno[^]
Be aware, that not all plugins are written with the same precaution as the main stream.


JQuery确实是一个JavaScript库但不提供铸铁保证以满足跨浏览器问题。这取决于您希望使用代码的浏览器以及您使用JQuery实现的目的。



还有其他库可能会有所帮助,但是再取决于你想要做什么。



如果你打算将JQuery用于除最基本的任务之外的任何事情,你将需要JavaScript的知识。如果你想掌握JavaScript,我会推荐David Flanagan的JavaScript The Definitive Guide。他还谈到了JQuery。



混淆Java和JavaScript这两个术语的人并非闻所未闻。 JavaScript最初被称为LiveScript,但由于Java的流行而被重命名。
JQuery is indeed a JavaScript library but does not offer cast-iron guarantees to cater for cross-browser issues. It depends on the browser(s) you wish to use your code on and what exactly you are using JQuery to achieve.

There are other libraries which may help, but again it depends on what you are trying to do.

You will need a knowledge of JavaScript if you intend to use JQuery for anything but the most basic of tasks. I would recommend "JavaScript The Definitive Guide" by David Flanagan if you want to master JavaScript. He also touches on JQuery.

People mixing up the terms Java and JavaScript is not unheard of. JavaScript was originally called LiveScript but was renamed due to the popularity of Java.


这篇关于Jquery& java脚本跨浏览器implment的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆