Shortcode reference
Six shortcodes. Every one of them can be copied from the admin rather than typed, and all but the newest have a permanent older name that still works, so nothing you pasted into a page years ago has to be touched.
Old names keep working forever. Every shortcode below except [bangcart_checkout], which arrived in 3.7.0, has a legacy alias from before the plugin was renamed. Both spellings do exactly the same thing, so there is never a reason to go back through your pages editing them.
[bangcart_button]
The Add to basket button for one product. Copy it from the Products tab, where each product has a Copy button shortcode control. Legacy name: [ssc_button].
[bangcart_button id="apple-pear-chutney"]
| Attribute | Default | What it does |
|---|---|---|
id | empty | The product id, exactly as it appears on the Products tab. Required. |
label | empty | Overrides the button text for this one placement. Left blank, it uses your shop-wide Add-to-basket label from the Design tab. |
If the id is missing, or does not match a product, the page shows a small amber note explaining why. Only logged-in administrators see it. A customer sees nothing at all, because a broken shortcode is your problem to fix, not theirs to read about.
[bangcart_cart]
The basket trigger, placed wherever you want it: a header, a builder layout, a widget area. It opens the same one basket the floating corner button opens, and wears the same icon and count bubble. Copy it from the Design tab. Legacy name: [ssc_cart].
[bangcart_cart size="28"]
[bangcart_cart size="24" color="inherit"]
| Attribute | Default | What it does |
|---|---|---|
size | 28 | Icon height in pixels. Clamped between 16 and 80. 28 suits most headers. |
color | brand | brand wears your Button colour from the Design tab. inherit takes the colour of the surrounding text instead, which usually reads better in a header. |
You can use this alongside the floating corner button, which is the sensible way to try it: place it in your header, see how it looks, and only then switch the corner button off. Every count bubble on the page shows the same number.
When your shop is closed this renders nothing at all. Not hidden, gone.
One honest limit. Classic WordPress navigation menus do not run shortcodes inside menu items, so pasting this into a menu label will not work. Headers built in a page builder, widget areas and block themes all run it perfectly well.
[bangcart_price]
Prints a product's current price, read live from the Products tab. Use it instead of typing a figure into your page, so changing a price in one place changes it everywhere. Copy it from the Products tab. Legacy name: [ssc_price].
[bangcart_price id="apple-pear-chutney"]
[bangcart_price id="apple-pear-chutney" tag="h3" size="24" weight="700" colour="accent"]
| Attribute | Default | What it does |
|---|---|---|
id | empty | The product id. Required. |
was | yes | During a shop-wide sale, shows the old price struck through beside the new one. Set to no to hide it. |
tag | span | The HTML element to use. Allowed: span, p, div, h1 to h6. Anything else falls back to span. |
class | empty | Extra CSS classes, on top of bangcart-price. |
font | empty | heading or text use your shop's font zones. inherit sets nothing. Any other value is treated as a font family name, which your page must already be loading. |
size | empty | A bare number is read as pixels. Otherwise px, rem, em, pt and % are accepted. |
weight | empty | 100 to 900 in hundreds, or normal, bold, lighter, bolder. |
colour / color | empty | accent, button, or a hex value such as #2a80c2. Both spellings work; colour wins if you somehow set both. |
A value that is not understood is ignored rather than guessed at, so a typo in size leaves the price at its inherited size instead of shrinking it to nothing.
The price it prints reflects your shop-wide sale, and only the sale. Quantity tiers and order-value rules from Pro depend on what else ends up in the basket, so the shortcode cannot know them in advance - during one of those promotions the page can understate the final discount, but it never promises one that does not happen. For a Pro customer-set-price product it prints nothing at all, because there is no fixed price to print.
[bangcart_thank_you]
The order confirmation customers land on after paying. Takes no attributes. Legacy name: [ssc_thank_you].
[bangcart_thank_you]
Put it on a page of its own, then nominate that page on the Settings tab under Thank-you page. There is a Create the page for me button there if you would rather not do it by hand.
Nominating the page is what matters. Without it, Stripe sends customers back to your home page and they never reach the shortcode at all.
It shows the customer their order reference, what they bought, the total, how they paid, and either their delivery address or your collection details. It does this only for a real completed payment, and only for 24 hours afterwards. After that the same address shows a plain thank-you with nothing personal on it. The page is never cached and never indexed while it is carrying an order.
[bangcart_checkout]
The page that carries Stripe's payment form when checkout happens on your own site. Takes no attributes, and has no legacy name - it arrived in 3.7.0.
[bangcart_checkout]
You will rarely place this one by hand. On the Settings tab, under Where customers pay, a button creates the page and puts the shortcode on it in one press. Pressing it twice does not make a second page.
This shortcode ships in the free plugin, but only Bang! Cart Pro fills it. The free plugin has no embedded payment form to put on the page - customers pay on Stripe's own site, and the page renders a note saying so to you and nobody else. With Pro, the same page carries Stripe's form inside your header and footer, and your address bar never changes. See Checkout on your own site.
[bangcart_sale_banner]
A banner announcing your shop-wide sale. Takes no attributes; everything about it comes from the Discounts tab. Legacy name: [sale_banner], which is the spelling the admin's copy button still hands out.
[bangcart_sale_banner]
It renders nothing at all unless a shop-wide sale is switched on with a percentage above zero, so you can leave it permanently in your template and it will appear and disappear on its own. Its message and text colour are set beside the sale itself; leave the message blank and it reads "20% off everything".
Copying rather than typing
Every shortcode the admin shows you can be clicked to copy, including ones woven into a line of help text. The dedicated Copy buttons are still there; the click-to-copy is on top of them, so you never have to select a shortcode by hand.
Still stuck?
Write to me and it is me who answers, not a ticket queue. Tell me what you expected and what happened instead.


