Skip to main content

Available hooks and filters in the StoreLinkr WordPress plugin

The StoreLinkr WordPress plugin provides several hooks and filters that allow developers to customize the behavior and appearance of the integration. These hooks follow the standard WordPress plugin architecture.

Frontend HTML and CSS

To ensure a consistent look and feel across different themes, StoreLinkr applies minimal default styling to product detail elements. You can use the following filters to customize or override these styles and structures.

CSS Customization

  • storelinkr_stock_css: Filter the CSS used for the stock locations table.
  • storelinkr_variant_css: Filter the CSS used for the variant dropdown styling.

HTML Structure

  • storelinkr_stock_html: Customize the HTML output for stock locations when a product is available in multiple locations. By default, this renders a table.
  • storelinkr_variant_html: Customize the HTML structure of the variant dropdown on the product details page.

Labels and UI Elements

  • storelinkr_variant_dropdown_label: Change the label displayed above the variant dropdown. Default: "Select variant".
  • storelinkr_attachment_label: Change the label for the product attachments tab. Default: "Attachments".

API and Configuration

These filters allow you to hook into the synchronization logic and data handling.

Product Visibility

  • storelinkr_single_visibility: When using Grouped Products for variants, this filter controls the visibility of individual child articles in the WooCommerce catalog.
    • Possible values: visible, catalog, search, hidden.
    • Default behavior typically sets child products to search (only visible when searched for, not in the main catalog).

Open Source Development

The StoreLinkr WordPress plugin is actively developed. For the most up-to-date implementation details and to see how these filters are applied in the source code, visit our GitHub repository.