Description
DigitalMakers Phone Mask with Flags for Contact Form 7 adds a phone field to Contact Form 7. You pick a country in the form settings, and the field gets the right mask, placeholder, and validation pattern.
What you get:
- Phone field with input mask (e.g. +38 (0__) _–-__)
- 130+ country masks and validation patterns
- Country flag next to the input (can be turned off)
- Client-side validation as the user types
- Server-side validation on submit
- Two display modes: plugin styles or your theme’s styles
- Per-form validation messages (CF7 Messages tab)
- Adjustable field size
- Default settings applied to new forms
- No external requests — all assets are local
- 20+ translations included
How it works:
- Install and activate the plugin.
- Open a Contact Form 7 form.
- Click the « Phone » button in the tag generator to insert a phone field.
- Open the « Phone Settings » tab, pick a country, set options.
- Don’t forget to fill in the « Message for incomplete phone number » and « Confirmation hint when phone number is complete » fields in the « Messages » tab.
- Save.
Supported countries:
130+ countries — United States, United Kingdom, Germany, France, Spain, Italy, Ukraine, Poland, Japan, Australia, Brazil, India, Canada and others.
Premium version:
If you need country switching on the frontend, dropdown search and extra themes, see CF7 Phone Mask DM Premium.
Third Party Libraries
The plugin bundles one third-party JS library:
- IMask.js — used for the input mask on the frontend.
- Source: https://github.com/uNmAnNeR/imaskjs
- License: MIT (Copyright (c) 2016 uNmAnNeR)
- License file:
assets/vendor/imask/LICENSE
It ships inside the plugin and is loaded with wp_enqueue_script(). No CDN calls.
Captures d’écrans






Installation
- Upload the
digitalmakers-phone-mask-with-flags-for-contact-form-7folder to/wp-content/plugins/or install via the WordPress plugin installer. - Activate the plugin through the « Plugins » menu in WordPress.
- Make sure Contact Form 7 is installed and active.
- Edit a CF7 form and click the « Phone » button in the tag generator toolbar to insert a phone field.
- Go to the « Phone Settings » tab in the form editor to select a country and configure display options.
- Save the form and add it to a page.
FAQ
-
Does this plugin require Contact Form 7?
-
Yes. CF7 must be installed and active. If it isn’t, the plugin shows a notice.
-
Can I use a different country for each form?
-
Yes. Country is picked per form in the Phone Settings tab.
-
Can I customize the validation messages?
-
Yes. Open the « Messages » tab in the form editor — there are two fields: « Message for incomplete phone number » and « Confirmation hint when phone number is complete ». They are saved per form.
-
Does the plugin load external resources?
-
No. JS and other assets are bundled with the plugin, no CDN calls.
-
Is the plugin compatible with page builders?
-
It works anywhere CF7 shortcodes work — Elementor, Divi, WPBakery and so on.
-
Can I hide the country flag?
-
Yes. Uncheck « Show country flag » in the Phone Settings tab.
-
What’s the difference between « Use theme styles » and plugin styles?
-
Both modes work the same. « Use theme styles » leaves the field almost unstyled so your theme controls the look. With it off, the plugin adds its own borders, shadow and focus styles.
Avis
Il n’y a aucun avis pour cette extension.
Contributeurs/contributrices & développeurs/développeuses
« DigitalMakers Phone Mask with Flags for Contact Form 7 » est un logiciel libre. Les personnes suivantes ont contribué à cette extension.
Contributeurs“DigitalMakers Phone Mask with Flags for Contact Form 7” a été traduit dans 1 locale. Remerciez l’équipe de traduction pour ses contributions.
Traduisez « DigitalMakers Phone Mask with Flags for Contact Form 7 » dans votre langue.
Le développement vous intéresse ?
Parcourir le code, consulter le SVN dépôt, ou s’inscrire au journal de développement par RSS.
Journal des modifications
1.0.5
- Country selector in admin is now an always-open listbox — type to filter, no dropdown to open
- Code cleanup: bootstrap refactor, consistent indentation in PHP files,
uninstall.phpswitched to$wpdb->prepare()+esc_like() - Fixed: stale
cf7pm_phone_settings_option with empty form id no longer leaks into new forms —get()andsave_phone_settings()require a valid form id - Added: bundled IMask LICENSE file and a Third Party Libraries section in readme.txt
1.0.4
- Internal release — not published to wordpress.org
1.0.3
- Fixed country search in admin — now matches country name and dialing code (e.g. « 380 », « +380 », « ukr »)
- Added country search to the global Default Country selector on the Settings page
1.0.2
- All POST data sanitized with
sanitize_text_field() - Removed redundant SQL queries and JSON reads
- Frontend assets load only when CF7 is present
- Per-form validation messages via the CF7 Messages tab
- Added a global default settings page
- Fixed validation pattern handling
- Removed the external CDN option — assets are bundled locally
- Removed unused methods and dead code
1.0.1
- Added static cache for phone masks JSON
- Added settings helper class
- Improved form tag handler
1.0.0
- Initial release
- Phone field with IMask integration
- 130+ country masks
- Client-side and server-side validation
- Country flag display
- Theme and plugin styling modes
