Archive for October, 2008
How To Use Google Analytics on Myspace

I received an interesting email from a reader last week about using Google Analytics on a Myspace profile. As most of you know Myspace does not allow for the addition of JavaScript into profiles, and up until now there has not been a solution to allow for this. Over the years I’ve received thousands of visitors looking for information about this, but I’ve never had a solid solution in which to offer up until now. Please note that this solution is for technically savvy users of Flash, but hopefully an easier solution can be built through a script or simply application. The reader proposed the following solution:
Simply put since Myspace allows embedding flash objects. You can create a flash file 1px by 1px with the same color background as your myspace page. Then you would call the javascript from the flash object as shown at (http://blog.projectx4.com/2008/03/28/google-analytics-flash-easy-peasy/).// GOOGLE ANALYTICS SIMPLE TRACKING /// Script by: corban baxter import flash.external.ExternalInterface; function gaTracking(page) { ExternalInterface.call(“pageTracker._trackPageview”, page); } //end// CODE FOR SIMPLE CALL IS BELOW \\
gaTracking(“/flash/home”); //sends event to google’s analytics system
Please note that I have not verified that this is in fact a permanent solution, but a very clever idea to solve the issue of getting web analytics tracking beyond Myspace’s rudimentary ‘views’ tab. Please feel free to provide comments, and I’ll be sure to update this post as reader’s give it a shot. Through community and heopfully with some web developers with a few spare moments users of Myspace will be able to tag their profiles with Google Analytics.