Đang chuẩn bị liên kết để tải về tài liệu:
Apress dot NET Test Automation Recipes_6

Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ

Tham khảo tài liệu 'apress dot net test automation recipes_6', công nghệ thông tin, cơ sở dữ liệu phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | CHAPTER 12 JQUERY Additional Effects In addition to the previous effects a number of additional effects can be downloaded fold pulsate puff bounce and explode my personal favorite . For more details on these effects please go to http docs. jquery.com UI Effects. Glimmer If you don t want to hand-code your jQuery effects you can use a great tool called Glimmer produced by Microsoft that offers a wizard-based approach see Figure 12-4 . Refer to http visitmix.com lab glimmer. Figure 12-4. Glimmer allows you to easily construct jQuery effects Glimmer allows the construction of simple effects such as rotating images drop-down menus and animation. jQuery Tools jQueryPad http www.paulstovell .com jquerypad and http jsbin.com can be very useful tools for prototyping and playing with jQuery. 282 CHAPTER 12 JQUERY Chaining Events The real power of jQuery comes from its capability to chain functions together. Imagine that we wanted to fade our div in and out a number of times. This procedure can be easily accomplished with the following code div1 .fadeOut .fadeIn .fadeOut .fadeIn .fadeOut Customizing jQuery You can add your own functions to the jQuery library. For example to create a simple function that will pop up an alert box you can do so with the following code don t use alias in case user overrides it jQuery.fn.say function message alert jQuery says message return this You can then call the new function with the following code .fn.say hello .say good bye And there is of course no reason why you couldn t write a new effects function and use it as part of a chain of effects. For more information please refer to http docs.jquery.com Plugins Authoring. AJAX Methods It is very common for performance optimization to need to retrieve data or code from an external source after a page is loaded. jQuery makes this very easy. Load and Run JavaScript File The following code loads an external JavaScript file called test.js and then executes it .ajax type GET url test.js dataType .