Hello all,
I am trying to integrate mautic in HTML page using Javascript. I have just deleted all my cookies from browser and trying to create new contact. It’s not reflecting in my mautic dashboard and i am not able to see cookie with mtc_id in browser cookie for my domain. So wanted to know when actually cookie creates in browser and when i can access it? I have scenario where i have to update cookie value in landing page itself.
Already checklist from myside
- I am not login in browser where i am login with my admin account.
- I have already tried to update values before i had removed cookie so my domain is set for cos request and javascript is at proper place.
I am placing my HTML Code below. can anyone check and let me know what’s the problem or flow when i can have mautic_id available in browser?
Landing Page
Have you watched video?
Have you downloaded pdf?
(function (w, d, t, u, n, a, m) {
w['MauticTrackingObject'] = n;
w[n] = w[n] || function () { (w[n].q = w[n].q || []).push(arguments) }, a = d.createElement(t),
m = d.getElementsByTagName(t)[0]; a.async = 1; a.src = u; m.parentNode.insertBefore(a, m)
})(window, document, 'script', 'https://web.fmtsolutions.com/mautic/mtc.js', 'mt');
mt('send', 'pageview');
</script>
<script type="text/javascript">
var _paq = _paq || [];
// tracker methods like "setCustomDimension" should be called before "trackPageView"
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function () {
var u = "//web.fmtsolutions.com/piwik/";
_paq.push(['setTrackerUrl', u + 'piwik.php']);
_paq.push(['setSiteId', '1']);
var d = document, g = d.createElement('script'), s = d.getElementsByTagName('script')[0];
g.type = 'text/javascript'; g.async = true; g.defer = true; g.src = u + 'piwik.js'; s.parentNode.insertBefore(g, s);
})();
</script>
<script>
$(document).ready(function () {
test();
$("#chk1").change(function () {
(function (w, d, t, u, n, a, m) { w['MauticTrackingObject'] = n; w[n] = w[n] || function () { (w[n].q = w[n].q || []).push(arguments) }, a = d.createElement(t), m = d.getElementsByTagName(t)[0]; a.async = 1; a.src = u; m.parentNode.insertBefore(a, m) })
(window, document, 'script', 'https://web.fmtsolutions.com/mautic/mtc.js', 'mt');
mt('send', 'pageview', { watchvideo: true});
});
});
function test() {
(function (w, d, t, u, n, a, m) { w['MauticTrackingObject'] = n; w[n] = w[n] || function () { (w[n].q = w[n].q || []).push(arguments) }, a = d.createElement(t), m = d.getElementsByTagName(t)[0]; a.async = 1; a.src = u; m.parentNode.insertBefore(a, m) })
(window, document, 'script', 'https://web.fmtsolutions.com/mautic/mtc.js', 'mt');
mt('send', 'pageview', { firstname: 'test78yu', lastname: 'shah56', zipcode: '97124', email: 'niytr677@yahoo.com', birth_year: 1987 });
}
</script>