How to access mysql queries used in page design
-
I am a new developer in wordpress and i am unable find page queries used in my product page.Comoplete code of my product page template is given below.Please guide me where mysql query stored against this template.Template code and mysql query is given below.
<?php
/**
* The template for displaying full width pages.
*
* Template Name: Full width
*
* @package storefront
*/get_header(); ?>
<div id=”primary” class=”content-area”>
<main id=”main” class=”site-main” role=”main”><?php while ( have_posts() ) : the_post();
do_action( ‘storefront_page_before’ );
get_template_part( ‘content’, ‘page’ );
/**
* Functions hooked in to storefront_page_after action
*
* @hooked storefront_display_comments – 10
*/
do_action( ‘storefront_page_after’ );endwhile; // End of the loop. ?>
</main><!– #main –>
</div><!– #primary –><?php
get_footer();Mysql query is given bleow.
SELECT SQL_CALC_FOUND_ROWS wp_bkkf_posts.ID
FROM wp_bkkf_posts
INNER JOIN wp_bkkf_postmeta
ON ( wp_bkkf_posts.ID = wp_bkkf_postmeta.post_id )
WHERE 1=1
AND
(
( wp_bkkf_postmeta.meta_key = ‘_visibility’
AND wp_bkkf_postmeta.meta_value IN (‘visible’,’catalog’)
)
)
AND wp_bkkf_posts.post_type = ‘product’
AND
( wp_bkkf_posts.post_status = ‘publish’
OR wp_bkkf_posts.post_status = ‘private’ )
GROUP BY wp_bkkf_posts.ID
ORDER BY wp_bkkf_posts.menu_order ASC,
wp_bkkf_posts.post_title ASC
LIMIT 0, 12Actully i want to change query but i am unable to find the query file.
Thanks
- The topic ‘How to access mysql queries used in page design’ is closed to new replies.