AHX WP Recipe releases
Rezepte verwalten, skalieren, anzeigen und für Bring! vorbereiten.
by Alexander Herbst · github.com/alexanderherbst/ahx_wp_recipe
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/alexanderherbst/ahx_wp_recipe/archive/refs/heads/master.zipWordPress plugin for managing recipes as a site-local custom post type. It works on single-site and multisite installations; each site has its own recipes and Bring! settings.
Features
- Backend dashboard under AHX Rezepte > Dashboard, shown as the first menu entry. It provides recipe/status counts, pending URL proposals, recipe-type and synonym-group counts, management shortcuts, up to eight oldest pending recipes for review, and the frontend shortcodes. Users without permission to edit others' posts see only their own recipe counts and review items; taxonomy and synonym management links respect their capabilities. Existing recipe list, type, import and synonym menus remain available. The dashboard is read-only; approval still takes place in the recipe editor.
- Recipe ingredients with quantities, units and steps, plus featured images from the WordPress media library.
- Recipe detail pages show featured and gallery images as compact 140 px previews. Clicking a preview opens the full image in a modal dialog, closed with the close button, Escape or a backdrop click. Without JavaScript or native dialog support, the preview links directly to the image file.
- Two display layouts: classic and cooking mode ("Kochmodus"), with ingredients beside the instructions. Cooking mode replaces the former split view ("Zweiteilig"); the old checklist mode has been removed. Recipes saved with the old checklist setting now use the new cooking mode.
- Cooking mode keeps the display awake using the Screen Wake Lock API while the page is visible. This also applies to recipes initially opened in cooking mode; switching to classic or leaving the page releases the lock, and returning to the page requests it again. Requires HTTPS and a supporting browser; device power-saving settings or denied browser permissions can still prevent the lock.
- Servings control scales numeric and fractional quantities. Published recipes on public HTTPS sites expose Schema.org Recipe microdata. The Bring! button uses Bring!'s recipe deep link with the recipe's own WordPress permalink and current servings so Bring! can parse the recipe and handle sign-in and native list selection. For unpublished recipes or sites without a public HTTPS URL, it copies all scaled ingredients and opens Bring! Web for manual entry. Ingredients have no checkboxes; shopping items are checked off in Bring!.
- Import of HTML, DOCX, PDF and TXT files, plus Chefkoch and Gaumenfreundin recipe URLs, into editable recipe drafts. Structured recipe data is read from schema.org JSON-LD; Gaumenfreundin's WP Recipe Maker ingredient fields preserve quantities, units, names and notes separately when available. Only HTTPS URLs on
chefkoch.deorgaumenfreundin.de(includingwww) are fetched, with redirects restricted to the original provider. PDF extraction requirespdftotext; DOCX extraction requires PHPZipArchive. Imported files with recognizable ingredient and instruction headings are split into fields; other text remains in the recipe editor for manual cleanup. - URL imports collect recipe images from schema.org data (plus additional Chefkoch recipe images from the page) and show a review step where the user picks which images actually belong to the recipe before the draft is created. Images are restricted to the supported provider domains and Chefkoch's CDN. The first selected image becomes the featured image, additional ones are stored as a gallery shown below it.
- Optional source field ("Quelle") per recipe, editable in the recipe editor. URL imports fill it in automatically with the source URL; published recipes show a source link on the frontend. Imported texts and photos retain their original rights; obtain the necessary permission before republishing them.
- Recipe archive at
/rezepte/and shortcode[ahx_wp_recipes](optional count:[ahx_wp_recipes number="8"]) display responsive image tiles grouped by recipe type. The archive includes all published recipes; the shortcode count limits distinct recipes, not tiles across groups. Recipes assigned to multiple types appear in each matching group; recipes without a type remain visible in an unassigned group. Missing featured images have a placeholder. - Manage recipe types under AHX Rezepte > Rezepttypen and assign one or more types in the recipe editor's Rezepttypen panel (or Quick Edit). Types use WordPress taxonomy storage and the REST API; existing recipes are not automatically classified.
- The archive and recipe-list shortcode include a pantry-based recipe finder: enter available ingredient names, optional decimal quantities and units, and the desired servings. Matching recipes are ranked within their type groups; missing ingredients, insufficient quantities and unchecked quantities appear on each tile. Multiple recipe types do not inflate the result count. The "all ingredients" filter excludes missing ingredients and known shortages, but recipes with unchecked quantities remain eligible and are marked accordingly.
- Pantry matching uses normalized ingredient names (case, accents and optional plural suffixes in parentheses), plus configured synonym groups. Autocomplete includes the aliases of ingredients used by the displayed recipes. Synonyms count as full matches, work in both directions and appear explicitly in the result details. Repeated recipe ingredients from the same synonym group are combined before comparing quantities so the same stock is not counted twice. Quantity comparison scales stored recipe amounts to the selected servings and converts g/kg and ml/l; pieces, tablespoons and teaspoons are compared within their own units. No weight/volume conversion is inferred. Unknown amounts, incompatible units and unspecified quantities are explicitly marked as unchecked. Pantry inputs are processed only in the browser, are not sent to a server and are not saved after reload.
- Administrators manage site-local synonym groups under AHX Rezepte > Zutaten-Synonyme: each group has a main name and alternative names, one per line. Starter groups cover Karotte/Möhre/Mohrrübe, Kartoffel/Kartoffeln, Zwiebel/Zwiebeln and Ei/Eier/Ei(er). Groups can be added, changed or removed; saving an empty list disables synonyms. Ambiguous names shared by different groups are rejected without replacing the existing configuration. Saving uses the WordPress Settings API with capability and nonce checks. Ingredient names stored in recipes are not rewritten. Substitute products are not automatically inferred or treated as synonyms.
- Frontend submissions use two separate shortcodes:
[ahx_wp_recipe_submit_recipe]for recipe entry and[ahx_wp_recipe_submit_url]for Chefkoch/Gaumenfreundin URL proposals. Place them on separate WordPress pages using a Shortcode block; each displays only its own permanently visible form with a heading and no expand/collapse control. The former combined[ahx_wp_recipe_submit]shortcode has been removed and must be replaced on any existing pages. The/rezepte/archive displays only the recipe collection and pantry finder, not submission forms. Visitors, including guests, can submit a recipe with title, optional description, servings, structured ingredients, preparation, existing recipe types and an optional JPG/PNG/WebP image. Uploads are limited to the smaller of 5 MB and the server's upload limit, and to 16 megapixels; files are checked server-side before creating a recipe. Submissions are always stored as Pending Review, never published automatically. - Recipe and URL proposal forms keep separate local drafts in IndexedDB, including the selected image. Drafts are scoped to the website and current WordPress user within that browser; they survive reloads but are not synchronized between devices. A successful Speichern response clears only the submitted draft. Validation, network and upload errors retain it. Browser storage restrictions or exhausted quota are reported; clearing browser data also removes drafts. Entwurf verwerfen deletes the current draft contents explicitly. Drafts on shared devices should be discarded or submitted before leaving.
- Review submissions in the AHX Rezepte list using its Pending status filter (German UI: Ausstehend); the Einreichung column distinguishes recipes and URL proposals. Edit and publish a manual recipe after review, or trash it to reject it. For a URL proposal, use URL importieren in the Frontend-Einreichung meta box: the existing import and image-selection workflow updates that proposal into an unpublished draft rather than creating a second recipe. Review it and publish afterwards. Unimported URL proposals cannot be published. Only HTTPS recipe URLs on
chefkoch.deandgaumenfreundin.deare accepted, and proposing a URL does not fetch the external page. Recipe-data availability is checked when the moderator imports the page. - Public submissions use WordPress nonces, a honeypot, a basic limit of 10 successful submissions per client IP per hour (stored as a salted hash), bounded fields, and per-submission idempotency/locking. These are basic abuse controls, not a replacement for a production anti-spam service. Uploaded images use normal WordPress media storage and URLs; pending recipe status does not make the underlying image file a private download.
Bring! setup
The plugin outputs Schema.org Recipe microdata for the recipe name, yield, image, ingredients and instructions. On published recipes with a public HTTPS permalink, it opens Bring!'s bringrecipes/deeplink with that permalink, base portion count and currently requested portion count. Bring! parses the recipe page, handles authentication and presents its native list selection. Drafts and recipes on non-public or non-HTTPS sites fall back to copying ingredients and opening Bring! Web at https://web.getbring.com/.
Multisite
Activate per site or network-activate. Recipes, media associations and Bring! settings are isolated by the active site, as with normal WordPress posts and options.
Releases
8 releases.
These releases are tags only. The author does not attach a packaged zip, so there are no download counts to report.