Forge12 Accessories for WooCommerce

Version 2.2.0  |  WordPress 5.8+  |  WooCommerce 6.0+  |  PHP 7.4+
forge12.com  |  Support: info@forge12.com

Table of Contents

  1. Installation
  2. Dashboard
  3. Adding Accessories to Products
  4. Category Assignment
  5. Optional Accessories Settings
  6. Layouts
  7. Display Options
  8. Cart Crossselling
  9. Design System
  10. Features Page
  11. Accessory Overview
  12. Shortcode
  13. Template Overrides
  14. Hooks & Filters
  15. FAQ

A. Installation

  1. Upload the f12-woo-accessoires folder to /wp-content/plugins/, or install via Plugins > Add New > Upload Plugin.
  2. Activate the plugin through the Plugins menu in WordPress.
  3. Navigate to Forge12 Accessories in the admin menu to configure the plugin.

System Requirements

RequirementMinimum
WordPress5.8
WooCommerce6.0
PHP7.4
HPOS Compatible This plugin is fully compatible with WooCommerce High-Performance Order Storage (HPOS).

B. Dashboard

The Dashboard is the starting page when you open Forge12 Accessories in the admin menu. It provides a quick overview of your accessory configuration.

Quick Stats

StatDescription
Products with AccessoriesNumber of products that have at least one accessory assigned.
Unique AccessoriesTotal number of distinct products used as accessories.
Total AssignmentsSum of all product-to-accessory relationships.
Features ActiveNumber of enabled features on the Features page.

Quick Actions

Shortcuts to the most important plugin pages: Settings, Features, Overview, and the WooCommerce product editor.

Pro Add-on If the Pro plugin is not installed, the Dashboard also shows a feature overview of available Pro features like Required Accessories, Smart Rules, and Analytics.

C. Adding Accessories to Products

Accessories are assigned on the product edit screen in WooCommerce.

  1. Go to Products > All Products and edit a product.
  2. In the Product data panel, click the Accessories tab.
  3. Use the search field to find products and click to add them.
  4. Drag and drop accessories in the list to reorder them.
  5. Click Update to save the product.

Accessory Picker

The unified accessory picker provides:

Product Metadata

FieldDescription
Optional AccessoriesProducts that customers can optionally add to their cart.
Custom TitleOverride the global section title for this product.
Custom DescriptionOverride the global section description for this product.
Deduplication If the same product is assigned as an accessory both directly and via a category, it will only appear once on the frontend.

D. Category Assignment

You can assign accessories to entire product categories. All products in that category will automatically display the assigned accessories.

  1. Go to Products > Categories.
  2. Edit a category (or add a new one).
  3. Scroll to the Optional Accessories field.
  4. Search and add products as accessories.
  5. Save the category.
Combine Both Product-level and category-level accessories are merged on the frontend. Use categories for general accessories (e.g., cleaning products for all furniture) and product-level for specific matches.

E. Optional Accessories Settings

Navigate to Forge12 Accessories > Optional Accessories to configure the display of optional accessories.

Basic Settings

SettingDescriptionDefault
Enable AccessoriesGlobally enable or disable optional accessories on the frontend.Enabled
Position Where accessories appear on the product page. Before product data tabs
Layout Choose how accessories are displayed. See Layouts. Grid
Grid ColumnsNumber of columns for the grid layout (2, 3, or 4).4
Title TypeHTML heading tag (h2–h6 or p) for the section title.h2
TitleCustom heading text displayed above the accessories.
DescriptionText displayed below the heading.

Position Options

PositionDescription
Before Add to Cart (Inline)Compact checkbox list between the price and Add to Cart button. Uses the Inline layout.
Before product data tabsBetween the product summary and the description/reviews tabs.
Before upsellsBelow the product tabs, before WooCommerce upsells.
Before related productsBelow upsells, before WooCommerce related products.
After related productsAt the very bottom of the product page.

F. Layouts

Grid Layout

The default layout. Accessories are displayed in a responsive product grid using WooCommerce's standard product card markup. Configurable from 2 to 4 columns.

List Layout

A single-column list layout. Each accessory is shown in a full-width row with image, title, price, and Add to Cart button.

Checkbox Layout (Frequently Bought Together)

A "Frequently Bought Together" style layout with checkboxes. Features include:

Inline Layout

A compact layout designed for the "Before Add to Cart" position. Characteristics:

Pro Layouts

The following layouts are available with the Pro add-on:

LayoutDescription
Slider ProResponsive carousel with autoplay, configurable slides per view, and navigation arrows.
Accordion ProCollapsible panels grouped by product category. Options: open first item, single open mode.
Tabs ProTab navigation grouped by product category.

G. Display Options

Control which product details are shown for each accessory item. These toggles are available in the Display Options section of the Optional Accessories settings.

OptionDescriptionDefault
Show Product ImageDisplay the product thumbnail.On
Show Product TitleDisplay the product name.On
Show PriceDisplay the product price.On
Show Star RatingDisplay the WooCommerce star rating.Off
Show Add to Cart ButtonDisplay the Add to Cart button.On
Show Stock StatusDisplay stock availability (In stock / Out of stock).Off
Show Short DescriptionDisplay the product short description.Off
Show SKUDisplay the product SKU.Off
Max AccessoriesMaximum number of accessories to display (0 = unlimited).0

H. Cart Crossselling

Display accessories from cart products on the cart page to encourage additional purchases.

Navigate to Forge12 Accessories > Cart to configure.

SettingDescriptionDefault
Enable in CartShow accessory suggestions on the cart page.Off
Title TypeHTML heading tag for the cart section.h2
TitleCustom heading text.
DescriptionText displayed below the heading.
Smart Filtering Accessories that are already in the cart will not be shown again. The plugin also prevents duplicate additions.

I. Design System

The Design System lets you customize the visual appearance of all accessory sections. Navigate to Forge12 Accessories > Design.

Global Colors

ColorUsageDefault
PrimaryButtons, active states, links#258dc8
Primary HoverButton hover states#1a6fa0
Text on PrimaryText on primary-colored backgrounds#ffffff
BackgroundSection and card backgrounds#ffffff
BorderCard and section borders#e0e0e0
TextBody text color#333333
PricePrice display color#111111
Badge / HighlightBadges and highlight elements#4caf50

Global Settings

SettingDescriptionDefault
Border RadiusCorner rounding for cards and buttons (0–20px).8px
Box ShadowEnable or disable card shadows.On

Preset Themes

Choose from four preset themes to quickly style your accessories:

Element-Specific Settings

Fine-tune the appearance of individual elements. Each element supports:

ElementDescription
ContainerThe outer wrapper of the accessories section.
CardIndividual product cards in the grid/list.
HeadingThe section title (e.g., "Optional Accessories").
DescriptionThe section description text.
Product TitleProduct names within accessory cards.
PricePrice display within cards.
ButtonAdd to Cart buttons.

Live Preview

The Design page includes a live preview panel that updates in real time as you adjust settings. This lets you see exactly how accessories will look before saving.

CSS Custom Properties All design settings are output as CSS custom properties (e.g., --f12-color-primary). Theme developers can override these in their stylesheets for full control.

J. Features Page

The Features page (Forge12 Accessories > Features) lets you enable or disable individual features. Only enabled features load their code, keeping the plugin lightweight.

Frontend Features

FeatureDescription
Gutenberg BlockPlace accessories on any page or post using the WordPress block editor.
Stock AlertsShow stock status badges (low stock, out of stock) on accessory items.
Product Preview ModalOpen a quick-view lightbox when clicking an accessory image.
Accessory GroupingGroup accessories by product category with tab navigation. Only appears when accessories span 2 or more categories.
Recommended BadgeMark specific accessories as "Recommended" with a customizable badge. Use the star icon in the product editor to toggle.

SEO & API

FeatureDescription
REST APIExpose accessory data via WooCommerce REST API endpoints.
Schema.org MarkupAdd isAccessoryOrSparePartFor structured data for search engines. Requires the REST API feature.

Admin Tools

FeatureDescription
Bulk AssignmentAssign accessories to multiple products at once. Filter by category or select products individually.
Inventory CheckDashboard overview showing all products and their accessory assignments with stock-level warnings.
Import / ExportExport and import accessory assignments via CSV files for bulk management.

Feature Tooltips

Each feature on the Features page includes an info tooltip with a detailed description of what it does and any dependencies.

K. Accessory Overview

The Overview page (Forge12 Accessories > Overview) provides a reverse lookup: see which products and categories use each accessory.

Features

L. Shortcode

Use the shortcode to display accessories anywhere on your site:

[f12-woo-accessories]

Place this shortcode on any page, post, or widget area. On product pages, it will display the accessories configured for that product. The shortcode respects all settings from the Optional Accessories page (layout, display options, etc.).

Gutenberg Block If you prefer the block editor, enable the Gutenberg Block feature on the Features page. This provides a visual block that wraps the shortcode.

M. Template Overrides

All frontend templates can be overridden from your theme. Copy the template file from the plugin into your theme directory and modify it.

Override Path

Copy from:

wp-content/plugins/f12-woo-accessoires/templates/{template-name}.php

To:

wp-content/themes/your-theme/f12-woo-accessoires/{template-name}.php

Available Templates

TemplateUsed For
woo-accessories.phpGrid and List layouts
woo-accessories-checkbox.phpCheckbox (Frequently Bought Together) layout
woo-accessories-inline.phpInline layout (Before Add to Cart)
woo-accessories-cart.phpCart crossselling section
woo-accessories-modal.phpProduct preview modal (lightbox)

Admin Templates

TemplateUsed For
admin-bulk-assignment.phpBulk assignment admin page
admin-inventory-check.phpInventory check admin page
admin-import-export.phpImport/export admin page

N. Hooks & Filters (Developers)

Actions

HookDescription
f12_woo_accessories_initFired after plugin bootstrap. Parameters: $Accessories, $UI. Used by the Pro add-on to initialize.
f12_woo_accessories_beforeFired before the accessories container is rendered.
f12_woo_accessories_afterFired after the accessories container is rendered.
f12_woo_accessories_item_badgeRender a badge on each accessory item (used by Recommended Badge and Stock Alerts).

Filters

FilterDescription
f12_woo_accessories_products_headingCustomize the section heading text. Parameters: $title, $product_id.
f12_woo_accessories_products_descriptionCustomize the section description text.
f12_woo_accessories_container_attrsAdd custom HTML attributes to the accessories container element.
f12_woo_accessories_item_attrsAdd custom HTML attributes to individual accessory items.
f12_woo_accessories_item_classAdd custom CSS classes to individual accessory items.
f12_woo_accessories_cartModify the list of accessories for cart crossselling.
f12_woo_accessories_cart_headingCustomize the cart section heading.
f12_woo_accessories_cart_descriptionCustomize the cart section description.
f12_woo_accessories_is_premiumReturns true when the Pro add-on is active with a valid license.

CSS Custom Properties

All design settings are available as CSS variables on the :root element:

/* Colors */
--f12-color-primary
--f12-color-primary-hover
--f12-color-primary-text
--f12-color-bg
--f12-color-border
--f12-color-text
--f12-color-price
--f12-color-badge

/* Layout */
--f12-border-radius
--f12-box-shadow

/* Element-specific (examples) */
--f12-heading-font-size
--f12-heading-font-weight
--f12-heading-color
--f12-card-padding
--f12-container-margin
--f12-button-font-size
/* ... and more for each element */

O. Frequently Asked Questions

Can I assign accessories to variable products?

Yes. Accessories can be assigned to any product type including simple, variable, grouped, and external products.

Will accessories be shown if they are out of stock?

By default, yes. If you enable the Stock Alerts feature, out-of-stock accessories will display a badge. WooCommerce's own stock settings control whether customers can still purchase them.

Can I use the same accessory for multiple products?

Yes. A product can be an accessory for any number of other products. Use the Overview page to see all assignments for a specific accessory.

How do category-level accessories interact with product-level accessories?

They are merged. If a product has its own accessories and also belongs to a category with accessories, both sets are displayed. Duplicates are automatically removed.

Can customers override my theme's styles?

The plugin uses CSS custom properties for all styling. You can override any variable in your theme's stylesheet. Alternatively, use the Design System to adjust the appearance without writing CSS.

Where can I get support?

Contact us at info@forge12.com or visit forge12.com.


© Forge12 Interactive  |  forge12.com