# Conflict with Prototype (Magento 1)

**URL:** <https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836>\
**Category:** Development\
**Created:** [June 28, 2017, 6:39pm UTC](https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836 "2017-06-28T18:39:10Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![luciosribeiro](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@luciosribeiro](https://forum.mautic.org/u/luciosribeiro)\
**Post date:** [June 28, 2017, 6:39pm UTC](https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836/1 "2017-06-28T18:39:10Z")

</div>

I’m having trouble using JavaScript tracking in Magento 1. As I researched, other developers also face the same difficulties. The problem occurs because of the conflict between mtc.js and prototype (of Magento 1).  
  
  
  
Is there any way to include the Mautic monitoring script by avoiding this conflict?

---

<div class="post-metadata">

**Author:** ![DerekBuntin](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/derekbuntin/32/90_2.png) [@DerekBuntin](https://forum.mautic.org/u/DerekBuntin)\
**Post date:** [June 30, 2017, 7:54pm UTC](https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836/2 "2017-06-30T19:54:19Z")

</div>

I’m seeing the same problem.

---

<div class="post-metadata">

**Author:** ![luciosribeiro](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@luciosribeiro](https://forum.mautic.org/u/luciosribeiro)\
**Post date:** [June 28, 2017, 6:39pm UTC](https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836/3 "2017-06-28T18:39:10Z")

</div>

I’m having trouble using JavaScript tracking in Magento 1. As I researched, other developers also face the same difficulties. The problem occurs because of the conflict between mtc.js and prototype (of Magento 1).

Is there any way to include the Mautic monitoring script by avoiding this conflict?

---

<div class="post-metadata">

**Author:** ![luciosribeiro](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@luciosribeiro](https://forum.mautic.org/u/luciosribeiro)\
**Post date:** [June 28, 2017, 6:42pm UTC](https://forum.mautic.org/t/conflict-with-prototype-magento-1/8836/4 "2017-06-28T18:42:22Z")

</div>

The following error appears in the browser console:

`
mtc.js:14 Uncaught TypeError: #<Object> is not a function
    at Array.forEach (<anonymous>)
    at HTMLDocument.<anonymous> (mtc.js:14)
    at Object.MauticJS.dispatchEvent (mtc.js:10)
    at mtc.js:71
    at XMLHttpRequest.xhr.onreadystatechange (mtc.js:7)
﻿`
