Đang chuẩn bị liên kết để tải về tài liệu:
JavaScript Bible, Gold Edition part 182
Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
JavaScript Bible, Gold Edition part 182. This book will bring programmers and non-technical professionals, including casual programmers and scripters, painlessly up to speed on all aspects of mastering JavaScript. Key topics include programming fundamentals, JavaScript language elements and how to use them effectively, and how to easily and efficiently add powerful new functionality to HTML documents and Java applets. | CD-302 Part VI Appendixes Listing 16-35 continued SCRIPT LANGUAGE JavaScript1.2 function page direction var pixFrame parent.display var deltaY pixFrame.innerHeight pixFrame.innerHeight pixFrame.document.body.scrollHeight if direction up deltaY -deltaY parent.display.scrollBy 0 deltaY function customScroll form parent.display.scrollBy parseInt form.x.value parselnt form.y.value SCRIPT HEAD BODY B ScrollBy Controller B FORM NAME custom Enter an Horizontal increment INPUT TYPE text NAME x VALUE 0 SIZE 4 and Vertical INPUT TYPE text NAME y VALUE 0 SIZE 4 value. BR Then INPUT TYPE button VALUE click to scrollBy onClick customScroll this.form HR INPUT TYPE button VALUE PageDown onClick page down INPUT TYPE button VALUE PageUp onClick page up FORM BODY HTML setCursor cursorType NN2 NN3 NN4 NN6 IE3 J1 IE3 J2 IE4 IE5 IE5.5 Compatibility windowObject.setCursor Appendix F Examples from Parts III and IV CD-303 Example Use The Evaluator Chapter 13 in NN6 to experiment with setting the cursor. After clicking the top text box in preparation for typing roll the cursor to a location atop an empty spot on the page. Then enter the following statements one at a time into the top text box and press Enter Return setCursorC wait setCursorC spinning setCursorC move After evaluating each statement roll the cursor around the page and notice where the cursor reverts to its normal appearance. setInterval expr msecDelay language setInterval funcRef msecDelay funcargl . funcargn NN2 NN3 NN4 NN6 IE3 J1 IE3 J2 IE4 IE5 IE5.5 Compatibility Example The demonstration of the setInterval method entails a two-framed environment. The framesetting document is shown in Listing 16-36. Listing 16-36 SetInterval Demonstration Frameset HTML HEAD TITLE setInterval Method TITLE HEAD FRAMESET R0WS 50 50 FRAME SRC lst16-37.htm NAME control FRAME SRC bofright.htm NAME display FRAMESET HTML windowObject.set nterval CD-304 Part VI Appendixes In the top frame is a control panel with several buttons that control the .