TAILIEUCHUNG - JavaScript Bible, Gold Edition part 165

JavaScript Bible, Gold Edition part 165. 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-132 Part VI Appendixes When you load Listing 15-8 only the first article of the Bill of Rights appears in a blue-bordered box. Buttons enable you to navigate to the previous and next articles in the series. Because the data source is a traditional tab-delimited file the nextField and prevField functions calculate the name of the next source field and assign the new value to the CataFld property. All of the data is already in the browser after the page loads so cycling through the records is as fast as the browser can reflow the page to accommodate the new content. Listing 15-8 Changing dataFld and dataSrc Properties HTML HEAD TITLE Data Binding TITLE STYLE TYPE text css display width 500px border 10px ridge blue padding 20px .hiddenControl display none STYLE SCRIPT LANGUAGE JavaScript function nextField var elem var fieldName var currFieldNum parseInt 7 10 currFieldNum currFieldNum 10 1 currFieldNum Article currFieldNum function prevField var elem var fieldName var currFieldNum parseInt 7 10 currFieldNum currFieldNum 1 10 --currFieldNum Article currFieldNum function toggleComplete if rights_raw column1 text hiddenControl else rights_html Article1 HTML SCRIPT HEAD Appendix F Examples from Parts III and IV CD-133 BODY P B . Bill of Rights B P FORM INPUT TYPE button VALUE Toggle Complete Individual onClick toggleComplete SPAN ID buttonWrapper CLASS INPUT TYPE button VALUE Prev onClick prevField INPUT TYPE button VALUE Next onClick nextField SPAN FORM DIV ID display DATASRC rights_html .

TỪ KHÓA LIÊN QUAN
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.