Zum Inhalt springen

Configuration

Dieser Inhalt ist noch nicht in deiner Sprache verfügbar.

All of Restock’s settings live on one screen, WooCommerce → Restock, and are stored as an array in the single restock_settings option. Each control carries an inline ? help button. Every text field is optional: leave it blank and the form, messages and email fall back to a built-in default (an empty string is dropped on save, so the code’s ?? $default lookup takes over). Checkboxes default on for guests, the product-page form and the My Account tab.

  • Allow guest subscriptions (allow_guests, default on), when on, anyone can join by entering an email. When off, only logged-in customers can subscribe and guests see the login required message.
  • Show form on product page (show_on_single, default on), auto-renders the form on out-of-stock and backorder products. Turn off only if you place the form yourself with the shortcode; with it off, even [restock_waitlist] returns nothing.
  • My Account waitlists (show_in_account, default on), adds the Waitlists tab. After toggling it on, resave Settings → Permalinks once if the tab 404s.
  • My Account menu label (account_menu_label), the menu wording; blank uses Waitlists. The item is inserted just before Log out.

The heading and intro each have a show/hide toggle and a text field, both must be set for the text to appear.

  • Show heading (show_title) + Heading text (title, placeholder Notify me when available).
  • Show intro text (show_intro) + Intro text (intro_text, placeholder Leave your email and we will let you know the moment this product is back.).
  • Email field label (email_label), the field’s accessible label, rendered as visually hidden screen-reader text.
  • Email field placeholder (email_placeholder), the greyed-out hint inside the empty field.
  • Consent checkbox label (privacy_label), text beside the required consent checkbox. Match it to your privacy policy; this is your responsibility.
  • Button text (button_text), the submit button label, e.g. Join Waitlist or Notify me.
  • Variable product prompt (variation_prompt_text), guidance shown above the form on variable products, telling shoppers to pick an unavailable variation first.

Shown after a submit, announced in an aria-live region. Blank uses the default.

  • Success (success_text)
  • Invalid email (invalid_email_text), malformed or missing address.
  • Missing consent (privacy_error_text), consent box not ticked.
  • Login required (login_required_text), only when guest subscriptions are off and the visitor is logged out.
  • Variation required (variation_required_text), a subscribe attempt that still resolves to a variable parent product.
  • Unsubscribe success (unsubscribe_success_text), after leaving a list from My Account.

The plain-text email sent on restock, through wp_mail:

  • Email subject (notify_subject), {product_name} is replaced with the product title.
  • Email intro text (notify_intro_text), the opening line; {product_name} is replaced here too. The product link is appended automatically on the next line.
  • Email closing text (notify_outro_text), the final line, after the link. No {product_name} substitution here.

A few behaviours are deliberately not settings, because they keep the form correct:

  • The form renders only for products that are out of stock or on backorder (variable products always output the wrapper, but the variation script keeps it hidden until an unavailable variation is chosen).
  • A consent checkbox is always required before a signup can submit.
  • Notifications fire automatically when WooCommerce sets stock status to instock, there is no manual “send” button and no cron to configure.
  • The My Account table texts (its heading, intro, empty-state and Leave waitlist button) use built-in defaults and are not exposed as settings.

Copy a template into your theme to change its markup; the override survives updates. Restock looks in the theme first, then its own templates/ folder:

  • Form: yourtheme/restock/single-product/waitlist-form.php
  • My Account table: yourtheme/restock/myaccount/waitlists.php

Developers can also adjust template data and paths with the restock/template/args and restock/template/path filters, see Using waitlists.

Subscribers live in one custom {prefix}_restock_waitlist table. The table has a unique key on (product_id, email), so a shopper can only sit on a product’s list once. Settings are in the restock_settings option; the applied schema version is tracked in restock_schema_version. Deleting the plugin runs the uninstall routine, which drops the table and removes both options, nothing is left behind. Restock contacts no external service.