Download the PHP package vizuh/craft-clicktrail without Composer

On this page you can find all versions of the php package vizuh/craft-clicktrail. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package craft-clicktrail

English | 中文

**vizuh/craft-clicktrail** See which campaign, keyword, click ID and landing page created each form submission, customer and Commerce order in Craft CMS.

CI Packagist Version

Index

Why

Not another analytics script. ClickTrail attaches deterministic first-touch / last-touch attribution to every lead and sale your Craft site produces and ships it server-side to your ClickTrail endpoint — so the answer to "where did this customer come from?" lives next to the record, not in a separate dashboard.

Attribution logic is never reimplemented here; the shared clicktrail/php-sdk core computes every payload.

Requires Craft CMS 5.0+ and PHP 8.2+. Optional: the Craft Forms plugin (form submissions) and Craft Commerce (orders).

Installation

Then install from Settings → Plugins, or:

Quick start

Read attribution directly in any site template:

A visitor arrives from a Google Ads ad, registers, then completes a Commerce order. Your ClickTrail endpoint receives three canonical events — lead_created, lead_created, sale — each stamped with the same immutable first touch (attribution.first.source === 'google', click ID preserved) plus the last touch at event time.

Event mapping

Platform-native events map onto canonical ClickTrail events:

Craft event ClickTrail event
Form submit (Forms plugin) lead_created
User registration lead_created
Commerce order completed sale
Commerce order refunded refund

Each mapping can be switched off individually in the settings.

Settings

All options live on the plugin settings page (Settings → ClickTrail):

Setting Default Purpose
Site ID empty Identifies this site to your ClickTrail account
Endpoint URL empty Where payloads are POSTed
Consent resolver class empty Custom ConsentResolverInterface implementation returning the normalized snapshot; empty = all signals "unknown"
Attribution persistence requires analytics_storage on Store nothing without granted analytics consent
Ad click-ID storage requires advertising_storage on Strip gclid/fbclid/... from storage without advertising consent
Send hashed lead data to ad destinations (ad_user_data) off Extra gate for hashed-lead forwarding; still needs ad_user_data granted
First-party proxy off Serve the ClickTrail loader from your own domain
Map form submissions on Emit lead_created on form submits
Map user registrations on Emit lead_created on registration
Map Commerce orders on Emit sale on order completion
Map refunds on Emit refund

Consent

ClickTrail does not replace your consent platform — it obeys it. The normalized consent contract (capabilities, snapshot shape, behavior matrix) lives in docs/consent-compatibility-plan.md.

Delivery

Payloads are POSTed as JSON to <endpoint>/events. Failed deliveries are logged as warnings so nothing disappears silently. Full transport (retries with backoff, idempotency keys) belongs to the shared SDK client once its wiring lands.

How it differs

Typical analytics setup ClickTrail for Craft
Sessions and pages in a dashboard Campaign, keyword, click ID and landing page on each submission, customer and order
Client-side tags you maintain yourself One Twig variable, one first-party loader
Attribution logic duplicated per platform One deterministic engine, fixture-tested across WordPress, GTM and PHP integrations

Testing

GitHub Actions CI lints all PHP files on every push (workflow).

License

MIT — Copyright (c) 2026 Vizuh OÜ. See LICENSE.


All versions of craft-clicktrail with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
craftcms/cms Version ^5.0
clicktrail/php-sdk Version dev-main
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package vizuh/craft-clicktrail contains the following files

Loading the files please wait ...