Problem Description #
When inserting the plugin’s shortcode or using the block on a custom page template or a page builder, the pricing table does not appear or behaves incorrectly.
Common symptoms:
- Shortcode prints nothing or only raw text.
- Table appears but scripts/styles don’t load, so it’s unstyled or non-interactive.
Cause:
Some themes and builders render content in ways that don’t execute plugin initialization code (e.g., content rendered by AJAX after page load, or template areas that bypass the_content filter).
Solution – step-by-step #
- Verify correct shortcode usage
Use the exact shortcode documented by WPFactory (see plugin docs). Example:
[wpfactory_price_by_quantity product_id=”123″]
- (Replace with the actual shortcode from docs.) WPFactory
- Test in regular page content
- Create a plain WordPress page (no builder) and place the shortcode in the editor. If it renders, the issue is with the builder/template.
- Ensure scripts/styles are enqueued
- Page builders or custom templates sometimes skip wp_footer() or wp_head() ensure your theme template calls wp_head() in <head> and wp_footer() before </body>. Missing these prevents plugin assets from loading.
- Use the plugin’s PHP template call if required (developer)
If the shortcode cannot be used in a specific template, include plugin output directly:
if ( function_exists( ‘wpfactory_price_by_quantity_render’ ) ) {
echo wpfactory_price_by_quantity_render( $product_id );
}
- (Ask WPFactory for the correct function name if different.)
- For AJAX-loaded content, re-initialize plugin after content loads
- If builder loads content via AJAX, use JS to re-run the plugin’s init function after content injection (developer required).
- Contact WPFactory with builder details
- Provide builder name, version, and reproduction steps; the author may provide compatibility guidance.
- Provide builder name, version, and reproduction steps; the author may provide compatibility guidance.
Prerequisites #
- Plugin docs for shortcode and template functions. WPFactory
Additional notes / prevention tips #
Keep a single canonical method to insert pricing tables (shortcode vs template) and document it in your theme/plugin guide.