If your comments in the code above reflect the file names then it’s a dash vs. underscore mistake.
Name of the second included file should be query-default.php
Related Posts:
- Passing variables through locate_template
- How to use get_template_part()?
- Is there a variable for a template parts name?
- How to make get_template_part always check child theme first?
- Check if partial file is called from within header.php or footer.php
- Too many get_template_parts?
- get_template_part() does not work if you call it when you are in a subfolder
- Pass a variable to get_template_part
- Getting the chosen template when iterating through pages
- Possible to use pagename inside get_template_part?
- Why would include(locate_template) work but not get_template_part()?
- How does get_template_part() work inside a loop?
- Is there a tirck in the get_xxxx function in the general_template.php file?
- Problem with using get_template_part() in footer
- how to remove get_template_part from a plugin? [closed]
- get_template_part() based on get_post_type() for a custom post type instead of get_post_format()
- Using get_template_part to retrieve a template file based on current post type
- add a hook with get_template_part()
- ä/ü/… are not displayed when including via get_template_part()
- Change the file path on get_template_part via plugin
- How to limit the number of Related Posts?
- get_template_part – how to find html file which is being render
- Get_Template_Part And Two Global WP_Query On Frontpage
- The use of get_template_part() returns ‘invalid argument’ loading options
- Passing a variable from the archive page to the default template
- For which reasons can get_template_part’s $args fail to work? (WP 5.8.1 – PHP 7.4.23)
- Can I set a global base path for get_template_part?
- how to use a different template (index.php) in wordpress
- What are the benefits of using get_template_part()?
- Include template file from plugin to theme
- get_template_part doesn’t output all data
- How to include a file using get_template_part() in a plugin?
- Using a custom WP_Query with get_template_part loop
- Is it possible to override the result of get_template_part()?
- Should we use get_template_part() in functions files instead of include_once?
- How to add custom content template part for a custom post type on main query using a plugin
- get_template_part from plugin
- Is it safe/recommended to use wp_enqueue_script function outside the functions.php file?
- Loading page content into a variable in template
- get_template_part execute with ajax
- _wp_page_template to dynamically use template
- Templates & CSS – Proper Programming Practice?
- Which custom query am I in and how can I access its properties & methods?
- Passing variables to template parts
- Correct way to use get_template_part() and get_post_format() with custom post types?
- How to pass variables with get_template_part?
- Finding Page Template and Displaying Content
- Unable to include a template
- Some doubts about how to show posts in a custom theme?
- get_template_part() – post-meta not working?
- Post Format single-loop.php using get_template_part
- Is there any way to get all the name or slug of template parts used in a page?
- How to get_template_part using AJAX?
- Valid HTML in Template Part
- add active class based on permalink and url
- How to show “teaser” posts on blog / archive pages, otherwise full posts
- Is there any problem if I use get_template_part like this?
- How to use taxonomy term as a value of get_template_part?
- get_template_part for specific page
- How do I make a variable available inside partials?
- Tag page only display 10 posts
- get_template_part causes 500 error
- Insert template-part inside the content
- Echo a shortcode div after every 3 posts
- Get Specific Template Part if Custom Field is Some Value
- How to reuse get_template_part() containing a simple loop to work with AJAX correctly?
- How to create new template page and template-parts in wordpress theme [closed]
- get_template_part() Not Working in Loop
- Remove get_template_part() from custom theme
- Displaying a custom post type using get_template_part into a specific layout
- get_template_directory() returns wrong address on VPS
- Get template part with CPT and Custom Taxonomy conditionals
- Can’t load search results with ajax
- Get_template_part() problem with the_content()
- Problem with Front-Page.php loading recent posts
- Including template pages within another template?
- get_template_part function and add images
- get_template_part() isn’t loading author information
- How to declare a variable in a loop and make it available in the template file
- Custom wp_query inside a conditional stament inside a template part doesn’t work: why?
- Using the get_template_part method within an mu-plugin not possible?
- get_template_part for template in subdirectory not working
- Blog template with different header to rest of site
- get_template_part calls amount and performance?
- How to use get_template_part always relatively to the file I’m using it in?
- Looking to load a different template part on every load/refresh
- Display post order ranking within wordpress loop
- Continue loop after $queryObject
- When using shortcode, content stops generating after the_content
- Removing get_template_part in child theme
- Is it possible to call a template file inside wysiwyg editor? And how?
- Is this correct get_template_part() in WordPress?
- get_template_part() to render single page Theme
- How return normal search result using wp_ajax action for wordpress
- Taxonomy template for all taxonomies attached to certain post type
- wordpress header leaks into body in a specific template
- strange parse error when including a loop template within another template
- Make a PHP file with a function
- Separate page for pagination possible?
- Access to a data from a response AJAX called in a template file php