Skip Appending UTMs on Some Links
The no-utm class is used to exclude specific links or elements from having UTM parameters appended to them by the handl-utm-grabber plugin. This can be useful in scenarios where you do not want tracking parameters to be added to certain URLs, such as internal links, mailto links, or other special cases.
Usage
To prevent UTM parameters from being appended to a link or element, simply add the no-utm class to the HTML element.
Example
<a href="https://example.com" class="no-utm">Example Link</a>
In this example, the link to https://example.com will not have any UTM parameters appended to it by the handl-utm-grabber plugin.
Detailed Explanation
The handl-utm-grabber plugin scans the page for links and elements to append UTM parameters for tracking purposes. By adding the no-utm class, you instruct the plugin to skip these elements during its processing.
Common Use Cases
- Internal Links: Prevent UTM parameters from being added to internal navigation links.
<a href="/about-us" class="no-utm">About Us</a>
- Mailto Links: Avoid appending UTM parameters to email links.
<a href="mailto:info@example.com" class="no-utm">Contact Us</a>
- Telephone Links: Exclude UTM parameters from phone number links.
<a href="tel:+1234567890" class="no-utm">Call Us</a>
- Special Cases: Any other links or elements where tracking is not desired.
<a href="https://example.com/special-case" class="no-utm">Special Case</a>
By using the no-utm class, you can have finer control over which links and elements are tracked with UTM parameters, ensuring that only the desired URLs are included in your tracking strategy.