How do I implement the JavaScript at the page source?
The website visit and the web page visit events are automatically generated when the Web Tracking script is loaded successfully on the web page.
Clicked a Link Events
To track the clicked link event, the implement the following function at the page source:
ewt.trackLink({name:'clickedeventname',type:'click',link:this'});
Example: < a href = www.thankyoupage.com id = "externalvisit" > onclick="return
ewt.trackLink({name:'aboutus, type: 'click', link:this});">Thank you </a>
File Download Events
To track the file downloads by a contact on your web site, include the following JavaScript function in your page source:
ewt.trackLink({name:'filename', type:'download'});
Example: < a href = whitepaper.pdf > onclick="return
ewt.trackLink({name:'whitepaper', type: 'download', link:this});">Click here to download the
whitepaper</a>
Form Submit Events
Tracks if the contact has submitted the form use:
ewt.trackFormSubmit({name:'formname', type:'form'});
Example: <form name="myform" action="actionpage.html" onSubmit =return
ewt.trackFormSubmit ({name:'Contact Us Form Submit',type:'form'});'>
Multimedia Events
Tracks if the visitor viewed a media file:
ewt.track({name:'videoname', type:'multimedia'});
Custom Events
You can define your own events to add events on your web page. Use the following function if you would like to generate a custom event:
ewt.track({name:'videoname', type:'custom event name'});
Example: If you wish to call a custom event for a mortgage calculator, then your code would look something like this:
<input name=calculator type= button value='Calculate' onclick =ewt.track({name:'mortgage',type:'mcalc'}); />
The type 'mcalc' is defined in your organization's Web Track Settings.
Conversion Tracking
You can define your own conversion tracking events using the function below. We support linear conversion tracking.
_blank (clicking a hyperlink that points to a new window)
Example
<a
href=''
target='_blank' onClick='javascript:return
ewt.cotLink({action:'Purchase',detail:'Laptop',amount:'499.00',link:this});'>Purchase
</a>
For more information, refer Conversion Tracking for additional functions.