WordPress Technology & Digital Applications 3 — Questions and Answers
Question 1: Which WordPress feature allows multiple websites to run from a single WordPress installation?
- WordPress Federation
- WordPress Multisite (Correct answer)
- WordPress Network Bridge
- WordPress Cluster
Correct answer: WordPress Multisite
WordPress Multisite (Network) lets you run multiple sites from one codebase and database, each with its own domain or subdirectory.
Question 2: What does the Gutenberg editor use as its fundamental building block?
- Shortcodes
- Widgets
- Blocks (Correct answer)
- Modules
Correct answer: Blocks
The Gutenberg block editor introduced in WordPress 5.0 uses discrete blocks for each content element like paragraphs, images, and headings.
Question 3: Which PHP global variable provides WordPress with database access methods?
- $db
- $wpdb (Correct answer)
- $database
- $mysqli
Correct answer: $wpdb
$wpdb is WordPress's global database object, an instance of the wpdb class that provides safe methods for querying MySQL.
Question 4: What is the purpose of the functions.php file in a WordPress theme?
- It stores theme color and font settings only
- It adds features and functionality to the theme by hooking into WordPress (Correct answer)
- It defines the theme's CSS variables
- It lists the theme's required plugins
Correct answer: It adds features and functionality to the theme by hooking into WordPress
functions.php acts like a plugin for the theme, allowing developers to add actions, filters, and custom functionality.
Question 5: Which WordPress constant, when set to true in wp-config.php, disables the plugin and theme file editor in the admin dashboard?
- DISALLOW_FILE_MODS
- DISALLOW_FILE_EDIT (Correct answer)
- DISABLE_EDITOR
- NO_FILE_EDIT
Correct answer: DISALLOW_FILE_EDIT
Setting DISALLOW_FILE_EDIT to true removes the built-in code editor from the Appearance and Plugins menus as a security measure.
Question 6: In WordPress, what is a 'taxonomy'?
- A database table for storing user roles
- A way to group and classify content using terms (Correct answer)
- A performance profiling tool for queries
- A type of custom plugin architecture
Correct answer: A way to group and classify content using terms
Taxonomies like Categories and Tags are grouping mechanisms; developers can also register custom taxonomies for any post type.
Question 7: What HTTP status code does WordPress typically return when a page is not found?
- 403
- 500
- 301
- 404 (Correct answer)
Correct answer: 404
WordPress returns a 404 Not Found status when a requested URL does not match any published content.
Which WordPress feature allows multiple websites to run from a single WordPress installation?