---
metadata:
  - name: generator
    content: Diplodoc Platform v5.55.2
alternate:
  - https://yandex.com/support/metrica/en/objects/enableall.md
  - https://yandex.com/support/metrica/es/objects/enableall.md
  - https://yandex.com/support/metrica/pt/objects/enableall.md
  - https://yandex.com/support/metrica/ru/objects/enableall.md
  - https://yandex.com/support/metrica/tr/objects/enableall.md
  - https://yandex.com/support/metrica/zh/objects/enableall.md
  - href: zh/objects/enableall.md
    type: text/markdown
    title: Markdown version
  - href: ../llms.txt
    type: text/markdown
    title: llms.txt
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.com/support/metrica/zh/llms.txt

# enableAll


{% note alert %}

过时方法。 向后兼容支持该方法，但可能随时弃用。 我们强烈不建议使用该方法。

默认情况下，会跟踪此方法控制收集和传输的所有数据。

要禁用跟踪特定数据，请在计数器初始化期间使用[clickmap](https://yandex.com/support/metrica/zh/code/counter-initialize.md#param-clickmap)、[trackLinks](https://yandex.com/support/metrica/zh/code/counter-initialize.md#param-trackLinks) 和[webvisor](https://yandex.com/support/metrica/zh/code/counter-initialize.md#param-webvisor) 参数。

{% endnote %}


```javascript
ym(XXXXXXXX, 'enableAll');
```

允许收集和传输以下信息：

- 有关生成 [click map](https://yandex.com/support/metrica/zh/behavior/click-map.md) 的点击的数据。 它的工作方式与 [clickmap](https://yandex.com/support/metrica/zh/objects/clickmap.md) (true) 一样。
- 有关出站点击和文件下载的数据。 与使用 [trackLinks](https://yandex.com/support/metrica/zh/objects/tracklinks.md)(true) 相同。 在生成 [click maps](https://yandex.com/support/metrica/zh/behavior/link-map.md) 以及 [Outbound clicks](https://yandex.com/support/metrica/zh/content/external-links.md) 和 [File downloads](https://yandex.com/support/metrica/zh/content/file-downloads.md) 报表时使用。

> # 示例
> 
> ```javascript
> ym(XXXXXXXX, 'init', {});
> ym(XXXXXXXX, 'enableAll');
> ```

<!-- source: zh/_includes/buttons/chat-button.md -->
[与我们聊天](https://yandex.com/chat/#/user/036e6a02-3620-9cdc-4c5e-a34667a7379e?utm_source=spravka){.button}

<!-- source: zh/_includes/styles/href-to-button.md -->

<!-- endsource: zh/_includes/styles/href-to-button.md -->
<!-- endsource: zh/_includes/buttons/chat-button.md -->

<!-- source: zh/_includes/buttons/support-button.md -->
<div class="cut-button">

{% cut "发送电子邮件" %}

<!-- source: zh/_includes/popup/id-popup/wrong-sup.md -->
请注意：我们的支持团队永远不会主动给您打电话。 请勿按照自称为 Yandex Metrica 支持团队来电者的指示操作。
<!-- endsource: zh/_includes/popup/id-popup/wrong-sup.md -->

<div style="padding: 15px;
     margin: 10px 0;
     background: #FFFFFF;
     border-radius: 10px;
     border: 1px solid var(--g-color-line-generic);">
  <iframe style="background: #FFFFFF;"
        height="700"
        width="100%"
        frameborder="0"
        src="https://forms.yandex.com/surveys/1706/?&iframe=1&lang=en">
  </iframe>
</div>

{% endcut %}

</div>

<!-- source: zh/_includes/styles/cut-button.md -->

<!-- endsource: zh/_includes/styles/cut-button.md -->
<!-- endsource: zh/_includes/buttons/support-button.md -->


[联系我们](https://yandex-ad.cn/contact){.button}


<!-- source: zh/_includes/styles/cut-button.md -->

<!-- endsource: zh/_includes/styles/cut-button.md -->

<!-- source: zh/_includes/styles/href-to-button.md -->

<!-- endsource: zh/_includes/styles/href-to-button.md -->

<!-- source: zh/_includes/footer-links.md -->
- - -

<div class="borderless-table">

#|
||
实用链接

- [演示计数器](https://metrica.yandex.com/r/dashboard?)
- [添加计数器](https://metrica.yandex.com/add/)
- [免费计数器设置](https://yandex.com/promo/freeservice/metrica?utm_source=help_metrica_en&utm_medium=cpc&utm_campaign=1)
- [Yandex Metrica API](https://tech.yandex.com/metrika/)
- [提出您的想法](https://yandex.com/support/metrica/troubleshooting/idea.html)
|
线上培训



- [参加培训课程](https://yandex.com/adv/edu/online/metrika?utm_source=metrika_help&utm_medium=web&utm_campaign=static&utm_content=useful_links)

||
|#

</div>

<!-- source: zh/_includes/styles/table-style.md -->

<!-- endsource: zh/_includes/styles/table-style.md -->
<!-- endsource: zh/_includes/footer-links.md -->
