Javasript and working with graphics

1. Which three are valid JavaScript variables?  (Choose three.)
2. Your new question!
3. Your code includes the following fragment:  <input type=”text” name=”text1″ id=”myText” />  You need to add code that will retrieve the contents of the INPUT element. Which JavaScript code fragment will accomplish this?
4. Which two code segments declare JavaScript functions? (Choose two.)
5. You need to use JavaScript to access the “section1” element in the following code fragment: <div id=’section1′>
Which method should you use?
6. Which JavaScript method is used to draw a circle on a canvas?
7. Which JavaScript code fragment will determine that a visitor has selected the “Chocolate” radio button? See link for code
<form action="#">
<p>What flavor do you prefer? <p/>
<input type="radio" name="flavor" if="vanilla" />vanilla<br />
<input type="radio" name="flavor" id="butterscotch" />Butterscotch<br />
<input type="radio" name="flavor" id="chocolate" />Chocolate<br />
</form>
8. You need to ensure the scope of a variable named j is limited to the block of a single function named foo(). Which JavaScript code fragment will accomplish this?
9. Which JavaScript method allows you to register multiple handlers for a single touch event?
10. You work as a senior developer at ABC.com. The ABC.com network consists of a single domain named ABC.com. ABC.com makes use of HTML5 and CSS3 in their development process. You have received instructions to create a page that has script tags included. You want to access an element by id by making use of JavaScript. You then want to add a class to the element. Which of the following actions should you take?

Name Email

Leave a Comment

Your email address will not be published. Required fields are marked *