1. Knowledge Base
  2. WooCommerce Lead Time
  3. Advanced Usage

How to display product lead times elsewhere on your site

The WooCommerce Lead Time plugin displays product lead times on the single product page. To ensure that the plugin works with all themes, we have coded it so that the lead time will only appear on the single product page, and not any other pages where your theme shows stock information.

We understand that you may sometimes wish to show lead times outside of the single product page. This article provides a choice of two methods for how to do this.

You may also like: How to change the position of the lead time on the product page

Using WooCommerce Product Table

WooCommerce Lead Time Product Table Integration

The simplest way to display lead times away from the single product page is to use our other plugin, WooCommerce Product Table.

WooCommerce Product Table lets you list any or all of your products anywhere on your site. You can either add it to standard pages in WordPress, or to your shop and category page template.

When you use WooCommerce Lead Time together with WooCommerce Product Table, you can add a lead-time column which displays the lead time within the product table.

WooCommerce Product Table
The easy way to list products with their lead time anywhere on your site!

Using WooCommerce Quick View Pro

WooCommerce Lead Time screenshot with quick view plugin

If you don’t want to list products in a table, then you can use another Barn2 plugin – WooCommerce Quick View Pro. This is also designed to work with WooCommerce Lead Time.

The plugin adds quick view buttons to your shop and category pages, allowing customers to view product information and purchase from a quick view lightbox instead of the single product page. Your lead times will appear in the lightbox, so it’s an ideal way to show the lead time away from the product page.

WooCommerce Quick View
The quick and easy way for customers to explore and buy more products.

Doing it programmatically

Alternatively, we have provided a template function so that you (or your developer) can display the lead time anywhere on your site.

Please note that this code is aimed at developers. If you don’t know how to use it, then we recommend posting a job on Codeable where one of their pre-approved WordPress experts will send you a quote. We have partnered with them to provide customizations for our plugins.

Need professional assistance?
We've partnered with Codeable to provide our customers with expert help if required.

You can retrieve the product lead time for custom display.by using the wclt_get_lead_time template function.

As an example, below we retrieve the lead time within a product loop.

$product = wc_get_product( get_the_ID() );
$lead_time = wclt_get_lead_time( $product );
Still need help?
If searching the knowledge base hasn't answered your question, please contact support.

Related Articles