Field Name Copier

Modifier+click on an Inputfield toggle copies the field name to clipboard.

ProcessWire 3.0.0+ PHP 7.1+ License MIT

Hold a modifier key and click any Inputfield header to copy the field’s machine name to the clipboard — without collapsing the field.

Useful when building templates, writing selectors, or debugging.

Features


  • Copies the field machine name on modifier + click
  • Field stays open (no collapse)
  • Resolves clean field names inside Repeaters and context-renamed fields
  • Optional toast confirmation
  • Works on any admin Inputfield (including AJAX-loaded fields)

Requirements


  • ProcessWire 3.0.0+
  • PHP 7.1+
  • Modern browser (current Chrome, Firefox, Edge, Safari)

Installation


  1. Copy the FieldNameCopier folder to /site/modules/ (rename from FieldNameCopier-main if downloaded as a ZIP).
  2. In the admin go to Modules → Refresh, then install Field Name Copier.

Usage


Hold the configured modifier key (default: Shift) and click the header/toggle of any Inputfield. The field name is copied to the clipboard. The field does not collapse. A small toast confirms the copy (if enabled).

Configuration


Modules → Field Name Copier → Configure

OptionDefaultDescription
Modifier keyShiftShift, Alt / Option, Ctrl, or Meta (⌘)
Show toast✓Brief on-screen confirmation after copying

Notes on modifier keys

  • Shift (Recommended): Works consistently across macOS, Windows, and Linux.
  • Alt / Option: Works on macOS and Windows; on some Linux desktops Alt+click is reserved for window dragging.
  • Ctrl: Works on Windows and Linux; on macOS Ctrl+click opens the browser context menu instead of firing a click event.
  • Meta (⌘): Intercepted by Windows; use only on macOS.

Behavior


  • Active only for logged-in users on non-AJAX, non-CLI admin pages.
  • Loads as a browser-cached external script via $config->scripts with config passed via $config->js().
  • Intercepts the click before ProcessWire’s accordion handlers collapse the field, while leaving links and header action icons untouched.
  • Reads the machine name from data-id / wrapper ID (stripping Repeater suffixes) and falls back to the field’s direct input name.
  • Works regardless of debug mode.

License


MIT License.

More modules by Daniel Zilli

  • Floating Page Save

    Shows a Save shortcut beside the page editor when space permits.
  • Field Name Copier

    Modifier+click on an Inputfield toggle copies the field name to clipboard.
  • Brazilian Portuguese (pt-BR) Language Pack

    Brazilian Portuguese (pt-BR) translation files for ProcessWire 3.x.
  • Icons Filter

    Enables filtering of icons by name in the InputfieldIcon view.
  • File Renamer

    Safely rename ProcessWire uploaded asset basenames from the admin.

All modules by Daniel Zilli

Install and use modules at your own risk. Always have a site and database backup before installing new modules.