Download the PHP package hamaryuginh/google-analytics-bundle without Composer

On this page you can find all versions of the php package hamaryuginh/google-analytics-bundle. 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 google-analytics-bundle

GoogleAnalyticsBundle

Work in progress

This Symfony bundle will simplify the management of interactions with google analytics.

Installation

Install composer

Add the following to your require block in composer.json config

Then, execute the following command in your symfony poject root

Configuration

Register the bundle in app/AppKernel.php:

Add to your app/config/config.yml the following:

Add the following before </head> tag:

At the end of your document, before the </body> tag, add:

Install assets (from your symfony project root):

Usage

Globally, you define a data-ga-xxx attribute on any tag and you give arguments as JSON string (ex: data-ga-page="{'page':'/home'}")

Page tracking

Add data-ga-page attribute on <body> tag or any other tag:

Or:

Or whatever you want...

Warning! data-ga-page must be defined only once per document !

For further information, take a look at the Page tracking documentation.

Custom dimentions and metrics

Add data-ga-dimension attribute on any tag:

For further information, take a look at the Custom dimensions and metrics documentation.

Event tracking (only "click" event at the moment)

Add data-ga-event attribute on any tag:

For further information, take a look at the Event tracking documentation.

Social interactions (only homemade social buttons at the moment)

Add data-ga-social attribute on any tag:

For further information, take a look at the Social interactions documentation.

Last but not least

Obviously, you can still use the Google Analytics library by the default way:

Ecommerce usage

1. Start the ecommerce tracking

Be sure to only declare this once and AFTER initializing the GA tracker (see Configuration)

2. Add a transaction

A transaction is like a basket

3.Add an item to the transaction

An item is a product in your basket. Add as many items in your transaction as you want.

4. Send the transaction to GA

Call this after having added all the items to the transaction.

Have fun!

Contributions

Feel free to open an issue or add a pull request.


All versions of google-analytics-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=5.4.0
symfony/framework-bundle Version >=2.5.6
twig/twig Version *
doctrine/doctrine-bundle Version *
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 hamaryuginh/google-analytics-bundle contains the following files

Loading the files please wait ....