课程: JavaScript Essential Training
今天就学习课程吧!
今天就开通帐号,24,600 门业界名师课程任您挑!
Challenge intro: Create an event listener - JavaScript教程
课程: JavaScript Essential Training
Challenge intro: Create an event listener
(upbeat music) - [Instructor] When a JavaScript application has interactive elements like buttons, or scroll events, or similar features, they're typically triggered using event listeners. In this challenge, you'll add event listeners to a list of form elements to allow the user to update fields in the document. Now the testing platform we're using doesn't have support to display the visible browser. So instead, I've created this sketch to show you what the DOM creates and this is the DOM you'll be working against. So on the webpage there are four pieces of information, name, description, color, and volume. And for each of these items there is the text itself and then there's an input field to update information and an update button. Your challenge is to set up the code so that if someone fills in any one of these fields and clicks on the update button for that field, the text updates as well, but only for that field.…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。
内容
-
-
-
-
-
-
-
-
-
-
-
(已锁定)
DOM events explained1 分钟 41 秒
-
(已锁定)
Typical DOM events5 分钟 35 秒
-
(已锁定)
Event listeners5 分钟 45 秒
-
(已锁定)
Practice: Experiment with event listeners1 分钟 32 秒
-
(已锁定)
Advanced event listeners and "this"6 分钟 12 秒
-
(已锁定)
Pass arguments through event listeners4 分钟 53 秒
-
(已锁定)
Challenge intro: Create an event listener2 分钟 15 秒
-
(已锁定)
Solution: Create an event listener6 分钟 16 秒
-
(已锁定)
-
-