Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
A Ruby Gem that allows you to add the Piwik Tracking Code to Sinatra, Padrinorb and Rails
Branch: master
Pull request Compare This branch is even with halfdan:master.

Merge pull request #17 from illogic-al/master

Wrap the image tracking code in a noscript tag.
latest commit 00942cf25e
@halfdan halfdan authored
Failed to load latest commit information.
app/views/piwik_analytics Put <img> tracker in <noscript> tag where it belongs
lib change async default back to false
spec Add some DRYness to this snippet and fix the tests as needed afterwards.
.travis.yml Travis config added
Gemfile Updating Gemfile
Gemfile.lock Updating Gemfile
MIT-LICENSE Update MIT-LICENSE
README.rdoc minor readme fix
Rakefile Rake spec as default task
init.rb
piwik_analytics.gemspec Bump version after fixing image tracking

README.rdoc

Build Status

PiwikAnalytics

Note: This Gem has undergone a major rewrite in 1.x compared to 0.9.x.

The piwik_analytics gem provides an easy way to include Piwik into your application. By default it will output the synchronous piwik tracking code for every page (given that it is configured correctly).

Installation

Add `piwik_analytics` to Gemfile:

gem 'piwik_analytics', '~> 1.0.0'

Run the generator:

rails g piwik_analytics:install

This will install a piwik.yml configuration file into the `config` directory of your application.

Configuration

Open up `config/piwik.yml` and edit the settings. Each setting is described in the config file itself.

Usage

Inside your `application.html.erb` (or haml, slim) simply add

<%= piwik_tracking_tag %>

Enjoy :)

Licence

Copyright© 2010-2012 Fabian Becker, released under MIT licence.

Something went wrong with that request. Please try again.