WebToffee Logo
  • Home
  • Plugins
  • Blog
  • Documentation
  • Support
Login
0

  • Getting Started
    • Plugin set up
  • Advanced Coupon Options
    • Display coupons using shortcodes
    • Giveaway Products
    • Automatically Apply Discount to Cart
    • Exclude Coupons/Store Credit from Applying
    • Coupons based on Shipping/Payment Method/Location
    • Restrict Auto Apply Coupons
    • Gift coupons on product purchase
    • Setup 'Seasonal discount offer'
    • Combo Coupons
    • Subscription Coupons
  • Store Credit
    • Set up store credit
    • Gift via store credit
    • Customize store credit template
    • Hide My Coupons & My Store Credit
  • Bulk Generate
    • Bulk Generate Coupons
  • Import Coupons
    • Bulk import coupons
    • Coupon Generator and Importer
  • BOGO discounts
    • Buy X and get X for 50% OFF
    • Set up BOGO
    • Quantity/Volume Discount Coupon
    • Spend $X and get Y at discount
  • Nth Order Discount
    • First order coupon
    • Offer nth order discount
  • SignUp Coupon
    • Configure SignUp Coupon
  • Abandoned Cart Discount
    • Offer Abandoned Cart Discount
  • Sales Countdown Timer
    • Set up sales countdown timer
  • FAQ
    • Hide coupon code field
  • Changelog
    • Version 2.0.4

Documentation/Smart Coupons for WooCommerce/Automatically apply discount to the cart with URL Coupon using Smart Coupon Shortcodes

Automatically apply discount to the cart with URL Coupon using Smart Coupon Shortcodes

Last updated on November 26, 2020

With URL Coupons, you can pass a coupon code in a URL and automatically apply it on any page by preserving the usage restrictions if any. It can be created by simply appending the coupon code along with the link. URL Coupons can be used in external sites or internally in your site for promoting your coupons that can be embedded within texts, images or anything similar that suits the theme of your website.  You can implement the URL coupon by using the following syntax:

<site_url>/?wt_coupon=<coupon_code>

For example, to implement a URL coupon in the cart page of a website www.webtoffee.com with the coupon code FLAT30, specify the URL coupon in the following format:

 https://www.webtoffee.com/cart/?wt_coupon=flat30

Suppose I have a page named sample page in my store. In order to pass a coupon code with a URL and to get it automatically applied, we need to create a link in the format as specified above. It is to be noted that the coupon URL can be applied to images, texts, etc. In this case, I have used the coupon shortcode for linking the URL.  Just copy and paste a coupon shortcode to this sample page and create a hyperlink. We can redirect the coupon URL to the cart page where it is automatically applied.

Note: A coupon shortcode is a unique code generated for each coupon created in your store. It can be used for illustrating the coupon with its configured style and description in whichever page as required to make the print advertising actionable. Shortcodes for the coupons are created by the Smart Coupon for Woocommerce plugin and it can be used internally in your site where it is installed.

URL Coupon with shortcode - demo

URL Coupon with shortcode – demo

On previewing the sample page, click on the coupon the user will be redirected to the cart page where the coupon is auto applied.

Coupon URL Demo

Coupon URL Demo

Visit our documentation and product page to know more about the smart coupon plugin.

  • Was this article helpful?
  • Yes, thanks!Not really

This article posted in Advanced Coupon Options, Documentation, Knowledge Base, Smart Coupons for WooCommerce

Written by

Shesna

Shesna is a technical content writer for WebToffee. She is familiar in working closely with the SMEs to break down complex technical information into a concise, easy to understand manner.

Got any query? Please leave a comment or reach out to our support

Cancel reply

Your email address will not be published. Required fields are marked *

We develop awesome WordPress plugins & WooCommerce extensions to help build successful online businesses.

© 2021 WebToffee. All rights reserved.

Our plugins

  • GDPR Cookie Consent
  • PDF Invoices & Packings Slips
  • Product Import Export Plugin
  • User & Customer Import Export
  • Import Export Suite
  • Sequential Order Numbers
  • Smart Coupons for WooCommerce
  • URL Coupons for WooCommerce
  • PayPal Express Checkout
  • Stripe Payment Gateway
  • Subscriptions for Woocommerce
  • Product Catalog Sync for Facebook
  • PrintNode for PDF Invoices
  • Order, coupon, subscriptions for WooCommerce
  • WordPress Backup and Migration
View more +

Get Started

  • Plugins
  • Testimonials
  • Affiliates
  • We're hiring

Help & Support

  • Documentation
  • Documentation (Basic)
  • FAQ
  • Support

Company

  • Terms & Conditions
  • Privacy Policy
  • Refund policy
  • Support policy
  • License Activation

© 2021 WebToffee. All rights reserved.

We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies. However you may visit Cookie Settings to provide a controlled consent.
Cookie settingsACCEPT
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of the basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website, to store user preferences and provide you with content and advertisements that are relevant. Such cookies will be stored on your browser but only upon procuring consent.

You will also have the option to opt-out of these cookies should you want to. But opting out of some of these cookies may have an effect on your browsing experience as per the descriptions elucidated against the respective categories below.

Necessary
Always Enabled

The cookies defines under this category are absolutely essential for the website to function. Hence they are loaded by default irrespective if user consent.

CookieDescription
PHPSESSIDThis cookie is native to PHP applications. The cookie is used to store and identify a users' unique session ID for the purpose of managing user sessions on the website. The cookie is a session cookie and is deleted when all the browser windows are closed.
viewed_cookie_policyThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not a user has consented to the use of cookies. It does not store any personal data.
Analytics

Analytics cookies help us understand how our visitors interact with the website. It helps us understand the number of visitors, where the visitors are coming from, and the pages they navigate. The cookies collect this data and are reported anonymously.

CookieDescription
_gaThis cookie is installed by Google Analytics. The cookie is used to calculate visitor, session, campaign data and keep track of site usage for the site's analytics report. The cookies store information anonymously and assigns a randomly generated number to identify unique visitors.
_gat_gtagIdentification code of website for tracking visits.
_gidThis cookie is installed by Google Analytics. The cookie is used to store information on how visitors use a website and helps in creating an analytics report of how the website is doing. The data collected including the number visitors, the source where they have come from, and the pages visited in an anonymous form.
_hjidHotjar cookie. This cookie is set when the customer first lands on a page with the Hotjar script. It is used to persist the random user ID, unique to that site on the browser. This ensures that behavior in subsequent visits to the same site will be attributed to the same user ID.
_hjIncludedInSampleThis cookie is set to let Hotjar know whether that visitor is included in the sample which is used to generate heatmaps, funnels, recordings, etc.
has_recent_activityThis cookie is used to signal to the code repository website if the user has browsed other website resources during the current session.
tk_aiGathers information for our own first-party analytics tool about how our services are used. A collection of internal metrics for user activity and is used to improve user experience.
tk_lrThis cookie is set by the JetPack plugin on sites using WooCommerce. This is a referral cookie used for analyzing referrer behavior for Jetpack.
tk_orThis cookie is set by the JetPack plugin on sites using WooCommerce. This is a referral cookie used for analyzing referrer behavior for Jetpack.
tk_qsGathers information for our own first-party analytics tool about how our services are used. A collection of internal metrics for user activity and is used to improve user experience.
tk_r3dThe cookie is installed by JetPack. Used for the internal metrics for user activities to improve user experience.
Advertisement

Advertisement cookies help us provide our visitors with relevant ads and marketing campaigns.

CookieDescription
_fbpThis cookie is set by Facebook to deliver advertisements when they are on Facebook or on a digital platform powered by Facebook advertising after visiting this website.
frThe cookie is set by Facebook to show relevant advertisements to the users and measure and improve the advertisements. The cookie also tracks the behavior of the user across the web on sites that have Facebook Pixel or Facebook social plugin.
Preferences

Preference cookies are used to store user preferences to provide them with content that is customized accordingly. This includes the language of the website or the location of the visitor.

CookieDescription
_gh_sessThis cookie is used to preserve users' states across page requests.
Save & Accept