Complete the code to include the main stylesheet in a WordPress theme.
wp_enqueue_style('theme-style', get_template_directory_uri() . '/[1]');
The main stylesheet file in a WordPress theme is style.css. It controls the look and feel of the site.
Complete the code to load the header template part in a WordPress theme.
get_[1]('header');
get_header() instead, which does not take parameters.The function get_template_part() loads template parts like the header or footer.
Fix the error in the code to properly register a navigation menu in WordPress.
register_nav_menu('[1]', 'Primary Menu');
Menu locations use slug names with hyphens, not spaces or underscores. primary-menu is correct.
Fill both blanks to create a child theme style enqueue that loads the parent style first.
wp_enqueue_style('child-style', get_stylesheet_uri(), array([1]), wp_get_theme()->get('Version'));
The child theme style depends on the parent style handle, usually 'parent-style', to load parent styles first.
Fill all three blanks to register and display a sidebar in a WordPress theme.
register_sidebar(array('name' => '[1]', 'id' => '[2]', 'before_widget' => '[3]'));
The sidebar needs a human-readable name, a slug id, and HTML before each widget. These are 'Main Sidebar', 'main-sidebar', and <div class='widget'>.