nerdexam
Microsoft

98-375 · Question #38

You develop an HTML5 webpage. You have the following HTML markup: <input type="text" id="username" /> You need to prevent users from entering specific characters into the username field. What should…

The correct answer is B. Using the change event, add an anonymous function that returns true when a specific. See the full explanation below for the reasoning.

Question

You develop an HTML5 webpage. You have the following HTML markup:

<input type="text" id="username" /> You need to prevent users from entering specific characters into the username field. What should you do?

Options

  • AUsing the keyup event, add an anonymous function that returns true when a specific
  • BUsing the change event, add an anonymous function that returns true when a specific
  • CUsing the keydown event, add an anonymous function that returns false when a specific
  • DUsing the change event, add an anonymous function that returns false when a specific

How the community answered

(35 responses)
  • A
    6% (2)
  • B
    83% (29)
  • C
    3% (1)
  • D
    9% (3)

Community Discussion

No community discussion yet for this question.

Full 98-375 Practice