There is a <pre> element, write a jQuery statement to get it's parent?

91. There is a <pre> element, write a jQuery statement to get it's parent?

  1. $("pre").parent();
  2. $("pre").parents();
  3. $("pre").parentsUntil();
  4. None of the above

Answer: A) $("pre").parent();

Explanation:

The correct jQuery statement to get the direct parent of a <pre> tag is:

$("pre").parent();

Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.