A shortcode lets you do nifty things with very little effort. Think of a shortcode as a shortcut to add features to your website that would normally require lots of complicated computer code and technical ability.
— WordPress Support
These shortcodes can be pasted into pages and posts to display products, clubs, utility menus, and registration forms with flexible custom settings.
-
Product Button
Displays a simple add to cart button for an individual SKU.
Example
[vs_product_button id="THE_PRODUCT_ID" sku="THE_SKU" icon="false" label="Add to Cart" quantity="1"]
These attributes may be added as parameters to the shortcode.
ID
String
Id of the product in VineSpring. Found at the end of the URL address when editing a product.
SKU
String
SKU on the product in VineSpring.
Icon
Boolean: true / false
Whether to display a cart icon before the label on the button.
Label
String
The label text displayed on the button.
Quantity
Number
The quantity of the product added to the cart.
-
Product
Displays a single SKU with product details and purchase form.
Example
[vs_product id="THE_PRODUCT_ID" image="true" name="true" teaser="true" description="true" form="true"]
These attributes may be added as parameters to the shortcode.
Image
Boolean: true/false
Whether to display.
Name
Boolean: true/false
Whether to display.
Teaser
Boolean: true/false
Whether to display.
Description
Boolean: true/false
Whether to display.
Form
Boolean: true/false
Whether to display.
-
Product List
Displays a product list.
Example
[vs_products tag="THE_PRODUCT_TAG" layout="THE_LAYOUT_NAME" heading="YOUR_HEADING" total="3"]
These attributes may be added as parameters to the shortcode.
Tag
String
The VineSpring product tag. Shows all products with tag. For all products, use ‘all’ or don’t include the tag attribute.
Layout
String
Allows you to use different layouts for displaying products. If no template attribute exists, uses the default product list from the VineSpring > Product List admin page. These layout names are valid by default:
- product-list-layout-1-col
- product-list-layout-2-col
- product-list-layout-3-col
- product-list-layout-4-col
- product-list-layout-custom
Heading
String
Displays custom heading text in a
h2
tag above the products. You can add your own heading above the shortcode and leave out the heading attribute.Total
Number
The total number of products displayed.
-
Clubs
Displays the clubs and details with the layout selected on the Clubs settings admin page.
Example
[vs_clubs]
There are no attribute parameters.
-
Club Join Button
Displays a club join button for an individual specified club.
Introduced in v1.1.7
Example
[vs_club_join id="club_5b7f00d26a5ef70001d8ed99" name="12 Bottle Club" label="Join the Club"]
The club and label attributes are required.
ID
String : true / false
The club ID from VineSpring, found in the URL of the individual club in VineSpring. Example, the club ID “club_5b7f00d26a5ef70001d8ed99” is found at the end of this club URL: https://app.vinespring.com/#/clubs/detail/club_5b7f00d26a5ef70001d8ed99
Name
String
The club name to be displayed on the clubs signup page. Example: “12 Bottle Club”
Label
String
The button label text. Example: “Join the Wine Club”
-
Register
Displays a registration form. Visibility can be toggled for address, comments, date of birth, phone, and source fields. Source field options inherit from the Register admin page settings.
Example
[vs_register address="false" comments="false" dob="false" phone="false" source="false"]
These attributes may be added as parameters to the shortcode.
Address
Boolean: true / false
Whether the address fields display.
Comments
Boolean: true / false
Whether the comments field displays.
DOB (Date of Birth)
Boolean: true / false
Whether the date of birth field displays.
Source
Boolean: true / false
Whether the source field displays.