Order By Post Type ThenBy Taxonomy

yes, offcourse it is possible, I had made two websites for selling car pieces myself and that is very possible. anything is possible. you can create your own search results with the file search.php here are two ways of getting products info: $args = array( ‘post_type’ => ‘product’, ‘posts_per_page’ => 10, ‘meta_key’ => ‘_last_viewed’, ‘orderby’ … Read more

custom permalinks based on taxonomies for custom post type

Permalink structure is a hierarchy, each level should be descendent of one another, be more specific i.e. shop.com/products/books/fiction/harry-potter where every book is a product, fiction is a genre of books and Harry Potter belongs to fiction books. So in your example product/manufacturer/brand/model every brand should belong to a single manufacturer and every model to a … Read more

How to display Custom Post Type Post based on Tag with Shortcode Parameter?

This is an answer that depending on how you ultimately configure things – should get you where you want to go. In your question, you had posts_per_page as 1. If you only want 1 result, then that’s fine. If not… modify as shown. You also didn’t initialize the concatenated string $return_string and finally you put … Read more

Send email button in custom post type backend

Solved this using AJAX. Here is my updated code: <?php add_action(‘wp_ajax_quote_email_pdf’, ‘quote_email_pdf’); function quote_email_pdf() { wp_mail( $to, $subject, $message, $headers, $attachments ); die(); } ?> <button class=”button” id=”downloadQuote”>Send email</button> <script> jQuery(document).ready(function($){ const fullName = $(‘#quoteFullName’).text(); const emailAddress = $(‘#quoteEmail a’).text(); $(‘#downloadQuote’).click(function(e){ e.preventDefault(); $.ajax({ url: sf_admin_ajax.sf_admin_ajax_url, type: ‘POST’, data: { action: ‘quote_email_pdf’, emailAddress: emailAddress, fullName: fullName … Read more

Disable featured image

It is definitely possible. We may need more info though. Do you know how to use page templates? Copy your single.php (or your page.php) from your theme and name it single-your-cpt-slug.php. (Replace ‘your-cpt-slug’ with your actual cpt slug). Within this file remove the call to the featured image. This is a pretty generic answer without … Read more