1 / 19
文档名称:

JQuery标签的使用-毕业论文外文翻译.docx

格式:docx   大小:249KB   页数:19页
下载后只包含 1 个 DOCX 格式的文档,没有任何的图纸或源代码,查看文件列表

如果您已付费下载过本站文档,您可以点这里二次下载

分享

预览

JQuery标签的使用-毕业论文外文翻译.docx

上传人:酒酿小樱桃 2017/6/17 文件大小:249 KB

下载得到文件列表

JQuery标签的使用-毕业论文外文翻译.docx

文档介绍

文档介绍:1 外文文献: DOM with jQuery utility functions — Using the jQuery flags Using the jQuery flags Some of the information jQuery makes available tous as page authors, and even plugin authors, is available not via methods or functions but as properties defined on $. Many of these flags are focused on helping us divine the capabilities of the current browser, but others help us control the behavior of jQuery ata page-global level. The jQuery flags intended for public use are as follows: $. — Enables or disabled effects $.support — Details supported features $.browser — Exposes browser details (officially deprecated) Let ’s start by looking athow jQuery lets us disable animations. Disabling animations There may be times when we might want to conditionally disable animations ina page that includes various animated effects. We might do so because we ’ve detected that the platform or device is unlikely to deal with them well, or perhaps for accessibility reasons. In any case, we don ’t need to resort to writing two pages, one with and one without animations. When we detect we ’ re in an animation-adverse environment, we can simply set the value of $. to true. This will not suppress any effects we ’ve used on the page; it will simply disable the animation of those effects. For example, the fade effects will show and hide the elements immediately, without the intervening animations. Similarly, calls to the animate() method will set the CSS properties to the specified final values without animating them. Using the jQuery flags One possible use-case for this flag might be for certain mobile devices or browsers that don ’t correctly support animations. In that case, you might want to turn off animations 2 so that the core functionality still $. flag isa read/write flag. The remaining predefined flags are meant tobe read-only. Let ’s take a look at the flag that gives us information on the environment provided by the user agent (browser). Det