A Chartbeat module for Zend Framework 2
This module will add Chartbeat tracking code to your ZF2 Application via the HeadScript and InlineScript View Helpers.
First, add the following line into your composer.json
file:
"require": {
"euphio/eph-chartbeat": ">=0.1"
}
Then, enable the module by adding EphChartbeat
in your application.config.php file.
<?php
return array(
'modules' => array(
'EphChartbeat',
'Application',
),
);
The following settings represent the configuration variables found at: http://chartbeat.com/docs/configuration_variables/
<?php
return array(
'chartbeat' => array(
'domain' => 'yourdomain.com', // Your Domain
'no_cookies' => false, // Disable Cookies?
'path' => '', // Path override
'uid' => '1234', // Your User id
'use_canonical' => false // Use canonical links?
),
);