Packagecom.happytoad.libs.riatrax
Classpublic class LinkButton
InheritanceLinkButton Inheritance mx.controls.LinkButton

The LinkButton component includes automatic Google Analytic tracking.

Copyright (c) 2009 HappyToad IT Consulting (http://www.happytoad.com)
Created by Rich Tretola (http://blog.everythingflex.com)

MXML Syntaxexpanded Hide MXML Syntax

The <rx:LinkButton> tag inherits all of the tag attributes of its superclass, and adds the following tag attributes:

   <rx:LinkButton
     Properties
     gaCategory="any"
     gaAction="any"
     gaLabel="any"
     gaValue="1"
     gaMode="unique|all|none"
     >
   

View the examples.

See also

com.happytoad.libs.riatrax.Tracker


Public Properties
 PropertyDefined by
  gaAction : String
String to be passed to Google as the Action property.
LinkButton
  gaCategory : String
String to be passed to Google as the Category property.
LinkButton
  gaLabel : String
String to be passed to Google as the Label property.
LinkButton
  gaMode : String
String to set tracking mode for compoment.
LinkButton
  gaValue : Number
Number to be passed to Google as the Value property.
LinkButton
Public Methods
 MethodDefined by
  
Constructor.
LinkButton
Property detail
gaActionproperty
gaAction:String  [read-write]

String to be passed to Google as the Action property.
An optional action for the event (e.g. "Play").

Implementation
    public function get gaAction():String
    public function set gaAction(value:String):void
gaCategoryproperty 
gaCategory:String  [read-write]

String to be passed to Google as the Category property.
An optional category for the event (e.g. "Videos").

Implementation
    public function get gaCategory():String
    public function set gaCategory(value:String):void
gaLabelproperty 
gaLabel:String  [read-write]

String to be passed to Google as the Label property.
An optional descriptor for the event.

Implementation
    public function get gaLabel():String
    public function set gaLabel(value:String):void
gaModeproperty 
gaMode:String  [read-write]

String to set tracking mode for compoment. ( unique | all | none )
This property defaults to unique. Set to all to track all events or none to disable tracking

Implementation
    public function get gaMode():String
    public function set gaMode(value:String):void
gaValueproperty 
gaValue:Number  [read-write]

Number to be passed to Google as the Value property.
An optional value to be aggregated with the event.

Implementation
    public function get gaValue():Number
    public function set gaValue(value:Number):void
Constructor detail
LinkButton()constructor
public function LinkButton()

Constructor.

Examples
LinkButtonExample
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
    xmlns:rx="com.happytoad.libs.riatrax.*"
    creationComplete="init()">
    
    <mx:Script>
        <![CDATA[
            import com.happytoad.libs.riatrax.Tracker;
            private var tracker:Tracker = Tracker.getInstance();
            private function init():void{
                tracker.account="UA-xxxxxx-y";
                tracker.display=this;
                tracker.visualDebug = true;
            }
        ]]>
    </mx:Script>
    
    <rx:LinkButton horizontalCenter="0" verticalCenter="0" label="Track Me"/>
    
</mx:Application>