Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Google Analytics for AS2

Explorer ,
May 12, 2009 May 12, 2009

Hi,

I created a web site in Actionscript 2 and have been asked to add Google Analytics to it. This is the first person who has asked me to do this and when I log into Google Analytics, they only provide the code for Actionscript 3. Apparently there used to be just Actionscript 2 code there but for a while it has just been AS3. I am told that the old code still works and I know that someone out there must have it. Can anyone help me out with it?

Thank you,

-Jan

TOPICS
ActionScript
10.6K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , May 12, 2009 May 12, 2009

http://blog.circlecube.com/2008/01/28/integrate-google-analytics-with-flash-tutorial/

Translate
Community Expert ,
May 19, 2009 May 19, 2009

per your comments, an action is required.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 19, 2009 May 19, 2009

I must be misinterpreting what the blog was saying. You are saying that I only need to use one value in the string since I am perfprming one operation?

Still so confused...

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 19, 2009 May 19, 2009

Do I just need import flash.external.*;
#include "logging.as"

at the top of the actionscript that I have for each swf that I want to track? Is the other code to track a specific event?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 19, 2009 May 19, 2009

in logging.as look at trackGA().  there are two parameters that are required and, i think, 2 that are optional.

if 2 are required, you must pass 2 each time trackGA() is called.  you're not doing that.

and there may be more errors beyond that.  i only check until i find an error.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 20, 2009 May 20, 2009

I made adjustments by adding the tracking code to each page as opposed to the navigation.

This is so frustrating. The Awstats picks up the swf files as well as the flv files without any additions to the code. The raw logs show all the files, swf and flv included. Why is Google Analytics so backwards that you have to jump through hoops writing code to track the swf and flv files. The owner of the web site is used to looking at the Google Stats and wants to use those. I am just really getting annoyed at this. The code is pinging the Google Stats but there is no differentiation from one swf to the next. This is so frustratingg!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 26, 2009 May 26, 2009

Even with the sample files, I am still unable to get this right. I still don't understand why Google Analytics can't track .swf and .flv files the way other stat programs can... I am a designer so this is very frustrating to me. I get no answers at all from Google... i see .swf and .flv in the raw data files so I don't understand why Google chooses to ignore those.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 26, 2009 May 26, 2009
LATEST

this is how the GA is tracking:

82973400:00:4369.07%65.86%$0.00
2.38413400:00:46100.00%33.07%$0.00
3.3117800:00:330.00%19.94%$0.00
4.1100:00:00100.00%100.00%$0.00
5.1100:00:00100.00%100.00%$0.00

This is how the Awstats is tracking:


Viewed

Average size

Entry

Exit

/index

1070

5.86 KB

959

836

/homeflv/ToMe.flv

51

2.20 MB

1

23

/homeflv/RecentTV_1.flv

41

26.97 MB

16

/homeflv/MR-Final-NoInstruct.flv

36

23.98 MB

1

17

/pdf/MR_01.pdf

31

102.42 KB

9

/pdf/MR_02.pdf

21

121.90 KB

5

/VIDflv/Genentech_1.flv

19

42.89 MB

1

7

/pdf/MR_06.pdf

19

90.58 KB

13

/workFLV/WhatIdo2.flv

16

3.57 MB

1

7

/fileman/fileman.cgi

16

15.95 KB

1

3

/VIDflv/FedEx_1.flv

15

21.79 MB

1

7

/pdf/MR_04.pdf

12

176.22 KB

3

/pdf/MR_03.pdf

11

98.42 KB

1

/workFLV/Delphi.flv

10

4.90 MB

4

/pdf/MR_05.pdf

9

171.19 KB

4

/VIDflv/mcgraw-4-21-09.flv

9

24.78 MB

2

/VIDflv/MR-Final-NoInstruct.flv

7

23.98 MB

3

/bioflv/TechKid2.flv

7

4.53 MB

1

4

/VIDflv/FamilyTrust_1.flv

6

16.33 MB

/VIDflv/Dow_1.flv

4

15.27 MB

1

1

/VIDflv/PlannedParenthood_1.flv

3

29.54 MB

2

/VIDflv/RecentTV_1.flv

3

26.97 MB

2

//homeflv/MR-Final-NoInstruct.flv

1

23.98 MB

1

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines