Lubinik Learning

Training mode

WordPress Intermediate Assessment

Time remaining:

0 / 50 answered

  1. 1. Which function is suitable for sanitizing a simple one-line text field?

    Which function is suitable for sanitizing a simple one-line text field?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  2. 2. What is WordPress?

    What is WordPress?
    Hint

    Start with the everyday meaning of the WordPress term.

  3. 3. Why should an uploaded filename not be trusted as a filesystem path?

    Why should an uploaded filename not be trusted as a filesystem path?
    Hint

    Treat names as input.

  4. 4. Which built-in taxonomy is non-hierarchical by default?

    Which built-in taxonomy is non-hierarchical by default?
    Hint

    Place the concept in the WordPress request, content, or permission model.

  5. 5. What is a widget area or sidebar?

    What is a widget area or sidebar?
    Hint

    Separate presentation responsibilities from reusable site functionality.

  6. 6. How are callbacks with the same priority generally ordered?

    How are callbacks with the same priority generally ordered?
    Hint

    Identify the role of the WordPress function or extension point.

  7. 7. Which style.css header links a child theme to its parent?

    The parent theme directory is named lubinik-theme.

    Which style.css header links a child theme to its parent?
    Hint

    The value must match the parent directory name.

  8. 8. What does a transient expiration guarantee?

    What does a transient expiration guarantee?
    Hint

    Consider lifecycle, authorization, failure and long-term maintenance.

  9. 9. Why should a post-type key be short, stable and uniquely prefixed?

    Why should a post-type key be short, stable and uniquely prefixed?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  10. 10. What are categories and tags in a default WordPress installation?

    What are categories and tags in a default WordPress installation?
    Hint

    Start with the everyday meaning of the WordPress term.

  11. 11. What must match when removing a callback with remove_action()?

    What must match when removing a callback with remove_action()?
    Hint

    A callback registered at priority 20 cannot be removed as though it used priority 10.

  12. 12. Which checks are important before accepting an uploaded file?

    Which checks are important before accepting an uploaded file?
    Hint

    Client-provided names and MIME values are not enough.

  13. 13. When should a custom taxonomy normally be registered?

    Choose the conventional WordPress lifecycle hook.

    When should a custom taxonomy normally be registered?
    Hint

    It is the same common lifecycle point used for CPT registration.

  14. 14. What is a taxonomy?

    What is a taxonomy?
    Hint

    Place the concept in the WordPress request, content, or permission model.

  15. 15. Which attack are WordPress nonces primarily intended to mitigate?

    Which attack are WordPress nonces primarily intended to mitigate?
    Hint

    They do not replace validation, escaping or authorization.

  16. 16. Why store a plugin database schema version?

    Why store a plugin database schema version?
    Hint

    Activation is not guaranteed to run during every deployment pattern.

  17. 17. What is the essential difference between a WordPress action and a filter?

    Choose the statement that correctly describes the contract expected by WordPress.

    What is the essential difference between a WordPress action and a filter?
    Hint

    Ask yourself whether the received value must continue through the execution chain.

  18. 18. Which function should be preferred when redirecting to a URL that must stay on an allowed host?

    Which function should be preferred when redirecting to a URL that must stay on an allowed host?
    Hint

    Escaping a string is not the same as validating a redirect destination.

  19. 19. Which callback runs first on the same hook?

    Which callback runs first on the same hook?
    Hint

    Identify the role of the WordPress function or extension point.

  20. 20. What does posts_per_page control?

    What does posts_per_page control?
    Hint

    Identify the WordPress API responsibility before considering implementation details.

  21. 21. Why must redirects and many HTTP headers be sent before body output?

    Why must redirects and many HTTP headers be sent before body output?
    Hint

    Place the concept in the WordPress request, content, or permission model.

  22. 22. What guarantee does a transient expiration provide?

    Consider external object caches as well as the database implementation.

    What guarantee does a transient expiration provide?
    Hint

    An expiration is a maximum lifetime, not a minimum lifetime.

  23. 23. Which endpoint receives traditional WordPress AJAX requests?

    Which endpoint receives traditional WordPress AJAX requests?
    Hint

    Consider lifecycle, authorization, failure and long-term maintenance.

  24. 24. Which checks belong in a save_post metabox handler?

    Select all generally appropriate safeguards.

    Which checks belong in a save_post metabox handler?
    Hint

    Consider request intent, autosaves, and authorization.

  25. 25. Which function registers a taxonomy?

    Which function registers a taxonomy?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  26. 26. What is the primary responsibility of a WordPress theme?

    What is the primary responsibility of a WordPress theme?
    Hint

    Start with the everyday meaning of the WordPress term.

  27. 27. What is a registered menu location?

    What is a registered menu location?
    Hint

    Separate presentation responsibilities from reusable site functionality.

  28. 28. On a standard single-site installation, which role normally has the broadest administrative access?

    On a standard single-site installation, which role normally has the broadest administrative access?
    Hint

    Start with the everyday meaning of the WordPress term.

  29. 29. Which task is normally associated with the Editor role?

    Which task is normally associated with the Editor role?
    Hint

    Start with the everyday meaning of the WordPress term.

  30. 30. What is The Loop in WordPress?

    What is The Loop in WordPress?
    Hint

    Identify the role of the WordPress function or extension point.

  31. 31. Which hook is designed for registering theme features?

    Which hook is designed for registering theme features?
    Hint

    Identify the role of the WordPress function or extension point.

  32. 32. What can WordPress attachment metadata contain for an image?

    What can WordPress attachment metadata contain for an image?
    Hint

    Place the concept in the WordPress request, content, or permission model.

  33. 33. Why check the expected HTTP method in a form handler?

    Why check the expected HTTP method in a form handler?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  34. 34. What is unusual about variable scope inside a plugin activation callback?

    What is unusual about variable scope inside a plugin activation callback?
    Hint

    Prefer explicit inputs and APIs.

  35. 35. What does get_footer() normally load?

    What does get_footer() normally load?
    Hint

    Separate presentation responsibilities from reusable site functionality.

  36. 36. What does relation control in a WP_Query meta_query?

    The query contains more than one metadata condition.

    What does relation control in a WP_Query meta_query?
    Hint

    Think of boolean logic between clauses.

  37. 37. Why should attaching a callback to the special all hook be approached carefully?

    Why should attaching a callback to the special all hook be approached carefully?
    Hint

    Broad instrumentation has a cost.

  38. 38. Which statements about WordPress nonces are correct?

    Select all correct answers.

    Which statements about WordPress nonces are correct?
    Hint

    A nonce verifies intent, not the user’s role or capabilities.

  39. 39. Why can an inline anonymous hook callback be difficult to remove later?

    Why can an inline anonymous hook callback be difficult to remove later?
    Hint

    Identify the role of the WordPress function or extension point.

  40. 40. What does body_class() help add?

    What does body_class() help add?
    Hint

    Identify the role of the WordPress function or extension point.

  41. 41. What does a WordPress nonce primarily verify?

    What does a WordPress nonce primarily verify?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  42. 42. What does has_post_thumbnail() check?

    What does has_post_thumbnail() check?
    Hint

    Identify the role of the WordPress function or extension point.

  43. 43. Which function prints a hidden nonce field for a form?

    Which function prints a hidden nonce field for a form?
    Hint

    Identify the data-model or security responsibility before choosing the API.

  44. 44. Why is a valid WordPress nonce not sufficient authorization?

    Why is a valid WordPress nonce not sufficient authorization?
    Hint

    Intent and permission are separate questions.

  45. 45. When should permanent plugin data normally be deleted?

    When should permanent plugin data normally be deleted?
    Hint

    A user may deactivate only to debug temporarily.

  46. 46. What is the difference between authentication and authorization?

    What is the difference between authentication and authorization?
    Hint

    Place the concept in the WordPress request, content, or permission model.

  47. 47. What does have_posts() check?

    What does have_posts() check?
    Hint

    Identify the role of the WordPress function or extension point.

  48. 48. Why pass a default value to get_option()?

    Why pass a default value to get_option()?
    Hint

    Consider lifecycle, authorization, failure and long-term maintenance.

  49. 49. What is dbDelta() designed to help with?

    What is dbDelta() designed to help with?
    Hint

    It is commonly used during versioned migrations.

  50. 50. Why should plugin functions and identifiers use a unique prefix or namespace?

    Why should plugin functions and identifiers use a unique prefix or namespace?
    Hint

    Identify the WordPress API responsibility before considering implementation details.