Linux 软件免费装
Banner图

NeedToMe Phone Number Switcher

开发者 needtome
更新时间 2026年10月16日 17:29
PHP版本: 7.4 及以上
WordPress版本: 7.1
版权: GPLv2 or later
版权网址: 版权信息

标签

marketing phone call tracking utm dynamic number insertion

下载

1.0.5

详情介绍:

NeedToMe Phone Number Switcher displays a campaign-specific phone number on your WordPress site. Create a rule with a URL parameter, an optional value, a CSS selector, and the replacement number. Use * in the parameter name to match a pattern such as utm_*. Features: Enter utm_source to match one parameter, or utm_* to match any parameter whose name begins with utm_. A rule with a blank parameter value matches whenever the parameter is present; enter a value such as newsletter to require an exact value match. Use a selector that targets the phone text itself, such as .header-phone or .contact-phone a. The new first-party cookie stores the IDs of matched rules so the same configured number can be shown on later pages. It does not store the visitor's IP address, URL, or phone number. During the transition, the plugin can also read the earlier pdxphone_for_utm cookie until it expires; that legacy cookie contains selectors and replacement numbers and is not written by this plugin. Site owners are responsible for documenting cookies used on their site and determining whether consent is required for their visitors. Campaign memory can be set to always remember the matching rule (the default), use the selected category from WP Consent API, or read a custom JavaScript consent signal. In consent-based modes, the number still changes on a page whose URL matches a rule. If consent is denied, the plugin clears and stops using campaign cookies; when the visitor opens a later page without the matching URL parameter, the original number remains. If the consent interface is unavailable or has not supplied a state, the plugin does not read or write campaign cookies.

安装:

  1. Upload the needtome-phone-number-switcher folder to the /wp-content/plugins/ directory, or install the plugin through the WordPress Plugins screen.
  2. Activate the plugin.
  3. Open Settings > NeedToMe Phone Number Switcher.
  4. Add a rule with a URL parameter, an optional value, CSS selector, and replacement number. Use * in the parameter name to match a pattern such as utm_*; leaving the value blank matches the parameter regardless of its value.
  5. Add the CSS selector to the phone text element in your theme or page builder and save the rule.
  6. Test the rule by opening a page with the matching parameter, for example https://example.com/contact/?utm_source=newsletter.

屏幕截图:

  • Live campaign demo showing the replacement phone numbers (`screenshot-2.png`).
  • Campaign-memory consent settings, shown in the Russian-language admin interface (`screenshot-3.png`).

常见问题:

Can I use a parameter other than UTM?

Yes. Enter any URL query parameter, such as campaign, ref, or gclid. Use * in the parameter name to match a pattern, and leave the parameter value blank to match its presence regardless of value.

Can NeedToMe Phone Number Switcher handle consent withdrawal for the campaign-memory cookie?

Yes. When connected to your cookie banner through the WordPress Consent API or a custom signal, NeedToMe Phone Number Switcher follows the category you select. If the visitor refuses that category or withdraws consent, the plugin deletes and stops using the campaign-memory cookie. The number still changes while a matching campaign URL is open; without that URL on a later page, the original number is shown. The plugin follows your banner's signal; it does not decide whether this cookie legally requires consent or certify GDPR compliance.

Can I connect a cookie banner that does not support the WordPress Consent API?

Yes, if the banner exposes a JavaScript value or function and emits an event when consent changes. Enter the state path, event name, and path to the consent value in the event details. The value must be true/false or a recognized consent state such as granted/denied.

Does the plugin change the phone number in the WordPress database?

No. It changes matching text in the visitor's browser. Your saved pages and posts are not modified.

Will it update click-to-call links?

Yes, when the selected element is an anchor whose href starts with tel:. The displayed number and telephone link are then updated together.

How does the plugin remember a campaign on later pages?

It stores the matching rule IDs in a first-party cookie. Set the duration to 0 to keep the choice for the current browser session only, or choose 1 to 365 days.

Do I need a call-tracking account?

No. The plugin maps a URL parameter to a phone number that you provide. It does not provision numbers or report calls.

What happens when the selector is invalid?

That rule is skipped in the browser. Check the selector in your theme or page builder and use the browser developer console to diagnose selector syntax.

What happens to settings when I delete the plugin?

Settings are retained by default. If you enable “Delete plugin settings when the plugin is deleted”, the plugin removes its settings and legacy PDX settings during uninstall.

更新日志:

1.0.5 1.0.4 1.0.3 1.0.2 1.0.0