Skip to navigation Skip to main content
Free on WordPress.org 4.9 · 13 reviews WordPress.org Explore both Plugins
Free on WordPress.org 4.9 · 13 reviews WordPress.org Explore both Plugins
  • WordPress
    Products
    Smart Cycle DiscountsDiscount automation › TrustLensCustomer trust intel › Cycle AI AIPlain-English campaigns ›
    New pluginComing soon
    Resources & toolsDocs, pricing, support ›
    Smart Cycle Discounts

    Smart Cycle Discounts

    Automate WooCommerce discount campaigns — schedule, target, and measure.

    62%
    Free Pro $59 5 discount types Recurring
    Jump into the page
    How it works Capabilities Promo codes Pricing
    Docs
    Getting started Discount types Scheduling
    Explore Smart Cycle Discounts → Changelog
    TrustLens

    TrustLens

    Customer trust intelligence — score buyers, spot abuse, protect revenue.

    Trust 86
    Free Pro $79 6 segments Abuse detection
    Jump into the page
    How it works Detection Outcomes Pricing
    Docs
    Trust scoring Detection modules Card-testing defense
    Explore TrustLens → Verify a report Changelog

    Cycle AI inside Smart Cycle Discounts

    Describe a sale in plain English — Cycle AI builds the whole campaign.

    “20% off hoodies this weekend”
    Included in Pro Natural language Catalog-aware
    See it work

    Type a sentence, get a ready-to-launch discount campaign that already understands your products, prices, and schedule.

    Live demo How it works
    Meet Cycle AI →

    A new plugin Coming soon

    Something is loading in the lab. Join the list to get the reveal first.

    Notify me on launch →

    Resources & tools

    Everything around the plugins — docs, free tools, and help.

    Learn
    Documentation Pricing & bundle Support
    Free tools
    Discount Calculator Sale Calendar
    Stay current
    SCD changelog TrustLens changelog
    Compare all plans →
    Secure checkout WordPress.org 14-day refund View pricing →
  • Affiliate
    Program
    OverviewHow the program works How it works4 steps from apply to earn Commission details30% · 60-day cookie · recurring
    Get started
    Apply nowOpen Takes ~2 minutes Earnings calculatorEstimate your monthly income FAQPayouts, cookies, renewals
    Resources
    Brand kitLogos, banners, copy, social PlaybookTactics that actually convert FTC disclosureHow to disclose properly Affiliate termsFull program agreement Contact teamOpen the contact form
    Earn 30% recurring on every saleFree to join · 60-day cookie · monthly PayPal payouts Apply now
  • Blog
  • DOCS
    Docs & resources

    Guides, references, and answers for every Webstepper plugin.

    Smart Cycle DiscountsAutomated WooCommerce discount campaigns
    Getting started› Discount types› Cycle AI›
    TrustLensCustomer trust & fraud intelligence
    Trust scoring› Detection modules› Card-testing defense›
    Docs home Guides FAQ Pricing Support
    WordPress tools that solve real problems
  • Contact Us
  • About
    Company

    Our Story

    Founded 2020

    Built by store owners, for store owners. We make WordPress tools that solve real problems.

    Learn more
    Built from experienceTools we use ourselves
    Time is preciousSimple, intuitive UX
    Real supportTalk to the founders
    Legal & contact
    Contact us Privacy policy Terms of service Refund policy
    14-day money-backNo questions asked
Popular requests
  • smart cycle discounts
  • trustlens
  • chargeback protection
GET STARTED

Getting Started

5
  • What is Smart Cycle Discounts?
  • Installation Guide
  • Creating Your First Campaign
  • Plugin Dashboard Overview
  • Free & Pro Features

Campaign Wizard

6
  • Campaign Wizard Overview
  • Step 1 – Basic Information
  • Step 2 – Product Selection
  • Step 3 – Discount Configuration
  • Step 4 – Campaign Scheduling
  • Step 5 – Review & Launch

Product Selection

5
  • All Products Mode
  • Specific Products Mode
  • Random Products Mode
  • Smart Selection Mode
  • Product Search Tips

Discount Types

8
  • Percentage Discounts
  • Fixed Amount Discount
  • Buy One Get One (BOGO)
  • Tiered Volume Pricing
  • Spend Threshold Discounts
  • Bundle Discounts
  • Discount Stacking and Priority
  • Coupon Code Campaigns

Scheduling

5
  • Setting Campaign Dates
  • Timezone Configuration
  • Recurring Campaigns
  • Campaign Status Explained
  • Automatic Activation

Campaign Management

7
  • Campaign List
  • Editing Existing Campaigns
  • Duplicating Campaigns
  • Bulk Actions
  • Campaign Priority System
  • Campaign Overview Panel
  • Campaign Intelligence System

Troubleshooting

6
  • Campaign Not Activating
  • Discounts Not Displaying
  • Scheduling Issues
  • Product Search Not Working
  • Performance Optimization
  • Common Error Messages

FAQ

3
  • General
  • Compatibility
  • Pricing & Licensing

Notifications

5
  • Email Provider Setup
  • Email Notifications Setup
  • Basic Notifications
  • Proactive Alerts
  • Low Stock Alerts

Setting Configuration

5
  • General Settings
  • Display Settings
  • Advanced Settings
  • Tools and Diagnostics
  • License Management

Use Cases

8
  • Coupon Code Campaign
  • Flash Sale Campaign
  • Seasonal Sale Campaign
  • Weekend Sale Recurring
  • BOGO Promotion
  • Volume Discount Campaign
  • Cart Threshold Promotion
  • Bundle Discount Campaign

Developer Documentation

5
  • Hooks and Filters Reference
  • Rest API Overview
  • Custom Discount Integration
  • Template Customization
  • Database Schema

Cycle AI

6
  • What is Cycle AI
  • Creating Campaign With AI
  • Refining With Conversation
  • Managing Campaigns With AI
  • Prompt Writing Tips
  • Rate Limit And Troubleshooting
View Categories
  • Home
  • Docs
  • Smart Cycle Discounts
  • Developer Documentation
  • Template Customization

Template Customization

4 min read

Smart Cycle Discounts uses template files for rendering certain UI elements. This guide explains how to customize these templates in your theme to match your store’s design.


Template Override System #

How Template Overrides Work #

Smart Cycle Discounts follows the WordPress/WooCommerce template override pattern:

  1. Plugin checks your theme for template file
  2. If found in theme, uses theme version
  3. If not found, uses plugin default

Override Location #

Place custom templates in your theme:

your-theme/
└── smart-cycle-discounts/
    └── [template-file.php]

Or in a child theme:

your-child-theme/
└── smart-cycle-discounts/
    └── [template-file.php]

Available Templates #

Frontend Templates #

Template Location Description
sale-badge.php frontend/ Product sale badge
savings-message.php frontend/ “You save X” message
price-display.php frontend/ Price with original/sale format
cart-discount.php frontend/ Cart discount row

Email Templates #

Template Location Description
campaign-expiring.php emails/ Expiration warning email
campaign-activated.php emails/ Activation notification
low-stock-alert.php emails/ Low stock warning (Pro)

Creating Template Overrides #

Step 1: Copy Original Template #

  1. Find the template in wp-content/plugins/smart-cycle-discounts/templates/
  2. Copy to your theme’s smart-cycle-discounts/ folder
  3. Maintain the same folder structure

Step 2: Customize Template #

Edit the copied file. Available variables are documented in each template.

Step 3: Clear Cache #

After changes, clear any page cache to see updates.


Template Examples #

Custom Sale Badge #

File: your-theme/smart-cycle-discounts/frontend/sale-badge.php

<?php
/**
 * Custom Sale Badge Template
 *
 * Available variables:
 * $product_id  - Product ID
 * $campaign    - Campaign object
 * $discount    - Discount percentage or amount
 * $badge_text  - Default badge text
 */

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}
?>

<div class="custom-sale-badge">
    <span class="badge-text"><?php echo esc_html( $badge_text ); ?></span>
    <span class="badge-discount">-<?php echo esc_html( $discount ); ?>%</span>
</div>

Custom Savings Message #

File: your-theme/smart-cycle-discounts/frontend/savings-message.php

<?php
/**
 * Custom Savings Message Template
 *
 * Available variables:
 * $savings_amount     - Amount saved
 * $savings_percentage - Percentage saved
 * $original_price     - Original price
 * $sale_price         - Sale price
 */

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}
?>

<div class="custom-savings">
    <strong>Your Discount:</strong>
    <span class="amount"><?php echo wc_price( $savings_amount ); ?></span>
    <span class="percent">(<?php echo esc_html( round( $savings_percentage ) ); ?>% off)</span>
</div>

Custom Price Display #

File: your-theme/smart-cycle-discounts/frontend/price-display.php

<?php
/**
 * Custom Price Display Template
 *
 * Available variables:
 * $original_price - Original price (float)
 * $sale_price     - Discounted price (float)
 * $product_id     - Product ID
 * $campaign_name  - Name of the campaign
 */

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}
?>

<div class="custom-price-display">
    <span class="was-price">
        Was: <del><?php echo wc_price( $original_price ); ?></del>
    </span>
    <span class="now-price">
        Now: <strong><?php echo wc_price( $sale_price ); ?></strong>
    </span>
</div>

CSS Customization #

Default CSS Classes #

The plugin adds these CSS classes you can target:

Class Element
.wsscd-discount-badge Sale badge container
.wsscd-original-price Original price (strikethrough)
.wsscd-sale-price Discounted price
.wsscd-savings-message Savings display
.wsscd-price-wrapper Price container
.wsscd-cart-discount Cart discount row

Adding Custom CSS #

Option 1: Theme Customizer

  1. Go to Appearance → Customize → Additional CSS
  2. Add your custom CSS

Option 2: Theme Stylesheet

/* In your theme's style.css or custom CSS file */

.wsscd-discount-badge {
    background: #ff4444;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-weight: bold;
}

.wsscd-savings-message {
    color: #28a745;
    font-size: 0.9em;
    margin-top: 5px;
}

Option 3: Display Settings

Use the custom CSS field in SC Discounts → Settings → Display.


JavaScript Customization #

JavaScript Events #

The plugin emits namespaced events. Common ones:

// Fired when dynamic content/DOM is refreshed.
$( document ).on( 'wsscd:content-updated', function() {
    console.log( 'Re-bind custom UI after plugin refresh.' );
} );

// Fired when a frontend countdown/offer expires.
$( document.body ).on( 'wsscd_discount_expired', function( e, $element ) {
    console.log( 'Discount expired for element:', $element );
} );

// Wizard event (admin).
$( document ).on( 'wsscd:wizard:stepLoaded', function( e, stepName ) {
    console.log( 'Wizard step loaded:', stepName );
} );

Modifying Display via JavaScript #

jQuery( function( $ ) {
    // Re-apply custom behavior after plugin-driven content updates.
    $( document ).on( 'wsscd:content-updated', function() {
        $( '.wsscd-discount-badge' ).addClass( 'is-enhanced' );
    } );
} );

Template Variables Reference #

Campaign Object #

When $campaign is available:

$campaign->get_id();           // Campaign ID
$campaign->get_name();         // Campaign name
$campaign->get_status();       // Status string
$campaign->get_discount_type(); // 'percentage' or 'fixed'
$campaign->get_discount_value(); // Discount amount
$campaign->get_priority();     // Priority level
$campaign->get_start_date();   // Start datetime
$campaign->get_end_date();     // End datetime

Price Variables #

$original_price    // Float: Original product price
$sale_price        // Float: Discounted price
$savings_amount    // Float: Amount saved
$savings_percentage // Float: Percentage saved

Product Variables #

$product_id        // Integer: WooCommerce product ID
$product           // WC_Product object (when available)

Email Template Customization #

Custom Email Template #

File: your-theme/smart-cycle-discounts/emails/campaign-expiring.php

<?php
/**
 * Campaign Expiring Email Template
 *
 * Available variables:
 * $campaign       - Campaign object
 * $days_remaining - Days until expiration
 * $site_name      - WordPress site name
 * $admin_url      - URL to campaign in admin
 */

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}
?>

<!DOCTYPE html>
<html>
<head>
    <style>
        body { font-family: Arial, sans-serif; }
        .header { background: #f8f9fa; padding: 20px; }
        .content { padding: 20px; }
        .button { background: #0073aa; color: white; padding: 10px 20px; text-decoration: none; }
    </style>
</head>
<body>
    <div class="header">
        <h1>Campaign Expiring Soon</h1>
    </div>
    <div class="content">
        <p>Your campaign "<?php echo esc_html( $campaign->get_name() ); ?>"
           will expire in <?php echo esc_html( $days_remaining ); ?> days.</p>

        <p><a href="<?php echo esc_url( $admin_url ); ?>" class="button">View Campaign</a></p>
    </div>
</body>
</html>

Best Practices #

Do’s #

  • Always escape output with esc_html(), esc_attr(), etc.
  • Check if variables exist before using
  • Use WordPress/WooCommerce functions where possible
  • Test in multiple browsers
  • Keep templates minimal and focused

Don’ts #

  • Don’t modify plugin files directly
  • Don’t include business logic in templates
  • Don’t hardcode URLs or IDs
  • Don’t forget to clear cache after changes

Updating After Plugin Updates #

When the plugin updates:

  1. Check changelog for template changes
  2. Compare your templates with updated originals
  3. Merge any new functionality into your overrides
  4. Test thoroughly after merging
Updated on February 17, 2026

What are your Feelings

  • Happy
  • Normal
  • Sad

Share This Article :

  • Facebook
  • X
  • LinkedIn
  • Pinterest
Custom Discount IntegrationDatabase Schema
Table of Contents
  • Template Override System
    • How Template Overrides Work
    • Override Location
  • Available Templates
    • Frontend Templates
    • Email Templates
  • Creating Template Overrides
    • Step 1: Copy Original Template
    • Step 2: Customize Template
    • Step 3: Clear Cache
  • Template Examples
    • Custom Sale Badge
    • Custom Savings Message
    • Custom Price Display
  • CSS Customization
    • Default CSS Classes
    • Adding Custom CSS
  • JavaScript Customization
    • JavaScript Events
    • Modifying Display via JavaScript
  • Template Variables Reference
    • Campaign Object
    • Price Variables
    • Product Variables
  • Email Template Customization
    • Custom Email Template
  • Campaign Expiring Soon
    • Best Practices
      • Do's
      • Don'ts
    • Updating After Plugin Updates
Newsletter

Insights that grow your business

Join thousands of WooCommerce store owners who get actionable tips, plugin updates, and industry news every week — plus 10% off either of our plugins as a welcome.

We respect your privacy. Unsubscribe at any time.

10% off welcome gift — A code for either plugin, on us
Weekly updates — Fresh content every Tuesday
Exclusive content — Tips you won't find on our blog
Early access — Be first to know about new plugins
Webstepper
Weekly WooCommerce Tips
Just now
This week: 5 proven strategies to boost your average order value using smart discount campaigns...
10% off inside
Webstepper

Tools for store owners who'd rather grow than grind.

Simple, powerful plugins that help WooCommerce store owners sell more — without the learning curve.

Products

  • Smart Cycle Discounts
  • TrustLens
  • Discount Calculator
  • Sale Calendar

Company

  • About Us
  • Blog
  • Contact
  • Affiliates
  • Log In

Resources

  • Help Center
  • Guides
  • Verify a report
  • Affiliate Program
  • Become a Partner

Questions? We actually answer.

Real humans, real help. No bots, no runaround. Usually within a few hours.

Get in touch
Operated by Setmood LLC · 7901 4th St N, St Petersburg, FL 33702 · United States

© 2026 Webstepper. All rights reserved.

Privacy Terms Refunds
Visa Mastercard PayPal Apple Pay Google Pay & more
Limited Time Offer

Get 10% off
Smart Cycle Discounts or TrustLens

Drop your email and we’ll send you a unique, single-use code — works on either plugin at checkout. New customers, first payment.

23 hours
:
59 minutes
:
59 seconds

No spam. Unsubscribe anytime.

  • WordPress
    Back
    Products
    Smart Cycle DiscountsDiscount automation › TrustLensCustomer trust intel › Cycle AI AIPlain-English campaigns ›
    New pluginComing soon
    Resources & toolsDocs, pricing, support ›
    Smart Cycle Discounts

    Smart Cycle Discounts

    Automate WooCommerce discount campaigns — schedule, target, and measure.

    62%
    Free Pro $59 5 discount types Recurring
    Jump into the page
    How it works Capabilities Promo codes Pricing
    Docs
    Getting started Discount types Scheduling
    Explore Smart Cycle Discounts → Changelog
    TrustLens

    TrustLens

    Customer trust intelligence — score buyers, spot abuse, protect revenue.

    Trust 86
    Free Pro $79 6 segments Abuse detection
    Jump into the page
    How it works Detection Outcomes Pricing
    Docs
    Trust scoring Detection modules Card-testing defense
    Explore TrustLens → Verify a report Changelog

    Cycle AI inside Smart Cycle Discounts

    Describe a sale in plain English — Cycle AI builds the whole campaign.

    “20% off hoodies this weekend”
    Included in Pro Natural language Catalog-aware
    See it work

    Type a sentence, get a ready-to-launch discount campaign that already understands your products, prices, and schedule.

    Live demo How it works
    Meet Cycle AI →

    A new plugin Coming soon

    Something is loading in the lab. Join the list to get the reveal first.

    Notify me on launch →

    Resources & tools

    Everything around the plugins — docs, free tools, and help.

    Learn
    Documentation Pricing & bundle Support
    Free tools
    Discount Calculator Sale Calendar
    Stay current
    SCD changelog TrustLens changelog
    Compare all plans →
    Secure checkout WordPress.org 14-day refund View pricing →
  • Affiliate
    Back
    Program
    OverviewHow the program works How it works4 steps from apply to earn Commission details30% · 60-day cookie · recurring
    Get started
    Apply nowOpen Takes ~2 minutes Earnings calculatorEstimate your monthly income FAQPayouts, cookies, renewals
    Resources
    Brand kitLogos, banners, copy, social PlaybookTactics that actually convert FTC disclosureHow to disclose properly Affiliate termsFull program agreement Contact teamOpen the contact form
    Earn 30% recurring on every saleFree to join · 60-day cookie · monthly PayPal payouts Apply now
  • Blog
  • DOCS
    Back
    Docs & resources

    Guides, references, and answers for every Webstepper plugin.

    Smart Cycle DiscountsAutomated WooCommerce discount campaigns
    Getting started› Discount types› Cycle AI›
    TrustLensCustomer trust & fraud intelligence
    Trust scoring› Detection modules› Card-testing defense›
    Docs home Guides FAQ Pricing Support
    WordPress tools that solve real problems
  • Contact Us
  • About
    Back
    Company

    Our Story

    Founded 2020

    Built by store owners, for store owners. We make WordPress tools that solve real problems.

    Learn more
    Built from experienceTools we use ourselves
    Time is preciousSimple, intuitive UX
    Real supportTalk to the founders
    Legal & contact
    Contact us Privacy policy Terms of service Refund policy
    14-day money-backNo questions asked
We use cookies to improve your experience on our website. By browsing this website, you agree to our use of cookies.
More info More info Accept