Metrica

replacePhones

Tip. Working with the JavaScript API requires knowledge of HTML and JavaScript. If you don't have these skills, contact your website developer or webmaster.

Replaces the phone numbers on the page for the Target Call tool at any time.

The set number replacement rules are triggered during counter initialization.

For elements formed after counter initialization, the replacement rules are not triggered. This could happen, for example, if the page content is generated or changed using JavaScript. In this case, number replacement requires calling the replacePhones function after the elements containing the fragments to be replaced have already been formed.

replacePhones()

Example

var yaCounterXXXXXX = new Ya.Metrika({id: XXXXXX});
yaCounterXXXXXXX.replacePhones();