Long forms are annoying to fill in twice, for example when a visitor leaves the page by accident, reloads it or comes back later. This module saves the entries of the forms you choose in the visitor’s browser while they type, and restores them the next time the form is shown.
Features
- Saves entries of text, email, number, date, phone and other input fields, text areas, checkboxes, radio buttons and dropdowns while the visitor is typing or selecting.
- Restores the saved entries automatically when the form is loaded again, also for fields that are added to the form later by scripts.
- The data is stored only in the visitor’s browser, not on the server.
- Several forms can share their stored data by using the same storage name.
- Each form can be limited to a specific page type.
Configuration
Go to Stores > Configuration > Infrangible Solutions > Form Storage > Settings > Forms (settings per website and store view) and add one row per form:
- “Selector”: the CSS selector of the form, for example its ID.
- “Storage Name”: optional name under which the data is stored; by default the name or ID of the form is used.
- “Layout Handle”: optional page type (layout handle) on which the form is watched, for example the contact page.
Good to know
- The stored entries stay in the browser until the visitor clears the browser data. Password fields are saved as well, so only use the module for forms without passwords or other sensitive data.
- The module uses the scripting of Magento’s standard (Luma-based) frontend; it is not built for the Hyvä theme.
Installation
Install the module with Composer in your Magento root directory:
composer require infrangible/m2-form-storageThen enable it and update the store as described in the installation guide. Composer installs the required modules listed on this page automatically.