| Package | yourminis.api |
| Class | public class Reporting |
| Implements | yourminis.api.IReporting |
var widget = ...
widget.reporting.trackURL("http://www.yourminis.com");
See also
| Property | Defined by | ||
|---|---|---|---|
| trackdata : XML [read-only]
Read-only access to the tracking data as a result of the call getTrackData();
| Reporting | ||
| Method | Defined by | ||
|---|---|---|---|
|
getTrackingData():void
Get user-specific tracking data including username, ipaddress, and geolocation information:
| Reporting | ||
|
trackClick(x:Number, y:Number, w:Number, h:Number):void
Used to track clicks within the widget.
| Reporting | ||
|
trackCopy(destination:String):void
Used to track the copying of a widget to a destination This is automatically called from the syndication panel.
| Reporting | ||
|
trackCustom(path:String, param:String = ""):void
Used to track custom actions within the widget
| Reporting | ||
|
trackInteraction():void
Used to track the start of widget interaction by the user.
| Reporting | ||
|
trackURL(url:*, target:String = "_blank", track:Boolean = true, navigate:Boolean = true):void
Used to both track URLs within a widget and/or navigate the user to the URL in the browser.
| Reporting | ||
| Constant | Defined by | ||
|---|---|---|---|
| REPORT_ONCLICK : String = "report-onclick" | Reporting | ||
| REPORT_ONCOPY : String = "report-oncopy" | Reporting | ||
| REPORT_ONGETURL : String = "report-ongeturl" | Reporting | ||
| REPORT_ONINTERACTION : String = "report-oninteraction" | Reporting | ||
| REPORT_ONVIEW : String = "report-onview" | Reporting | ||
| REPORT_TRACKDATA : String = "report-trackdata" | Reporting | ||
| trackdata | property |
trackdata:XML [read-only]Read-only access to the tracking data as a result of the call getTrackData();
Implementation public function get trackdata():XML
See also
| getTrackingData | () | method |
public function getTrackingData():voidGet user-specific tracking data including username, ipaddress, and geolocation information:
See also
var widget = ...
function onTrackData(evt:Event)
{
var trackdata:XML = evt.target.reporting.trackdata;
var ipaddress = trackdata.net.ipaddress;
...
}
widget.addEventListener(widget.reporting.REPORT_TRACKDATA,onTrackData);
widget.reporting.getTrackingData();
<tracking>
<user><loginname>yourminis/jeremy</loginname></user>
<i18n><lang>en-us</lang><lang>en</lang></i18n>
<net><ipaddress>192.168.1.101</ipaddress></net>
<geo>
<country code='US'>United States</country>
<region>CT</region>
<city>Fairfield</city>
<lat>41.1854</lat>
<long>-73.2645</long>
<postalcode></postalcode>
<areacode>203</areacode>
<dmacode>501</dmacode>
</geo>
</tracking>| trackClick | () | method |
public function trackClick(x:Number, y:Number, w:Number, h:Number):voidUsed to track clicks within the widget. Called automatically whenever the mouse is clicked over the widget (link, button, etc).
Parametersx:Number |
|
y:Number |
|
w:Number |
|
h:Number |
See also
| trackCopy | () | method |
public function trackCopy(destination:String):voidUsed to track the copying of a widget to a destination This is automatically called from the syndication panel. If your widget allows custom copying, then you can use this method to track it.
Parametersdestination:String |
See also
var widget = ...
widget.reporting.trackCopy("some-cool-destination");
| trackCustom | () | method |
public function trackCustom(path:String, param:String = ""):voidUsed to track custom actions within the widget
Parameterspath:String — The unique name given for the action to track
|
|
param:String (default = "") — An optional parameter to record for reporting filtering/grouping of this custom action
|
See also
var widget = ...
widget.reporting.trackCustom("search","cool products");
| trackInteraction | () | method |
public function trackInteraction():voidUsed to track the start of widget interaction by the user. This is automatically called when a user hovers over the widget.
See also
var widget = ... widget.reporting.trackInteraction();
| trackURL | () | method |
public function trackURL(url:*, target:String = "_blank", track:Boolean = true, navigate:Boolean = true):voidUsed to both track URLs within a widget and/or navigate the user to the URL in the browser. (required for external URL support in myspace.com)
Parametersurl:* — The URL to track and/or navigate to
|
|
target:String (default = "_blank") — An optional parameter to specify the target window name
|
|
track:Boolean (default = true) — An optional parameter to enable/disable tracking
|
|
navigate:Boolean (default = true) — An optional parameter to enable/disable browser navigation
|
See also
var widget = ...
widget.reporting.trackURL("http://www.yourminis.com/developers/");
var widget = ...
widget.reporting.trackURL("http://www.example.com/api/some-api-call",null,true,false);
| REPORT_ONCLICK | constant |
public const REPORT_ONCLICK:String = "report-onclick"
| REPORT_ONCOPY | constant |
public const REPORT_ONCOPY:String = "report-oncopy"
| REPORT_ONGETURL | constant |
public const REPORT_ONGETURL:String = "report-ongeturl"
| REPORT_ONINTERACTION | constant |
public const REPORT_ONINTERACTION:String = "report-oninteraction"
| REPORT_ONVIEW | constant |
public const REPORT_ONVIEW:String = "report-onview"
| REPORT_TRACKDATA | constant |
public const REPORT_TRACKDATA:String = "report-trackdata"