ActionScript for Flash MX: The Definitive Guide is structured so non-programmers can learn how to use ActionScript and programmers can take their skills to new heights. If you are in the market to really learn about the hows and whys of ActionScript, then this is the book for you.
Flash and SEO. Why not?
Google learns to crawl Flash
Google has been developing a new algorithm for indexing textual content in Flash files…
Source: http://googleblog.blogspot.com/2008/06/google-learns-to-crawl-flash.html
How to SEO Flash
• Search Engines and Flash
• Requirements for Successful Use of Flash
• SEO Flash Programming
• Example: Making Flash Home Page Spiderable
• Scalable Inman Flash Replacement
Source: http://www.hochmanconsultants.com/articles/seo-friendly-flash.shtml
Here are a few comments on this topic from SearchEngineGuide.com:
“Stoney, You hit the nail on the head and pounded it down with one stroke. I completely agree, I have turned down clients in my own business due to flash sites. Now that I am with an agency I find Flash more common, as many of the businesses are big enough and niched enough where they feel that they don’t need SEO for their website. Oddly enough they are often right. Unfortunately SEO can have a big effect on PPC marketing, and most of these accounts suffer from bad keyword quality scores and thus higher click costs in AdWords.”
“Susan: I disagree slightly. Mostly because it all comes down to the intent. Building a flash only website for Ozzy Osbourne is fine, but e-commerce is not. I think you know what I mean”
“ Working on seo for hotel sites, I’ve come across some stunning creative sites designed with Flash. If the designers had thoughtfully used the Flash applications to “wow” site visitors, ie embedding in otherwise SE-friendly pages, it could be a win-win situation.
Perhaps all of you have seen the June info about making Flash SE-friendly. ( http://googleblog.blogspot.com/2008/06/google-learns-to-crawl-flash.html )”
Source: http://www.searchengineguide.com/stoney-degeyter/why-i-still-wont-seo-flash-websites.php
And from SearchEngineJournal.com:
“Disney does it. And so does Oprah. Even my favorite pizza place does it… Granted these are extreme cases of sites which use flash extensively, but there are other cases where even a little flash can be improperly used. There are also cases where flash is not only appropriate, it is recommended. The question then becomes how to best use flash without affecting search engine rankings”
“Yeah this article doesn’t help a bit. I thought after reading I would be able to find a solution for my all flash website for seo purposes. Thefwa.com is an all flash website, they rank no.1, they didn’t follow your mumbo jumbo about not using too much flash” (Note from Alex: TheFWA.com does not rank no.1. They rank 31,905. Still not bad for an all flash site.)
Source: http://www.searchenginejournal.com/flash-and-seo-using-flash-on-websites/2247/
Cool online tool that will probe a flash file:
http://www.flashprobe.com/
Flash string search replace using prototype
How to preform a string search and replace in flash using actionscript prototype
Continue Reading »
Create buttons using AS3 in Adobe CS3 and CS4
How to make a button work in AS3 like AS2
Flash AS3 and IE Popup Blocker Fix
Flash button events are blocked sometimes some internet browsers bult-in popup blockers (ad blockers). I had this problem in the past in AS2 with IE on a PC. I could usably resolve the AS2 popup problem by changing the mouse event from onClick to onRelease or by changing the target from _blank to _self.
As with most AS3 code, the workaround is a bit more complicated. We can resolve this problem by calling a Javascript function via Actionscrip using the ExternalInterfac class.
function getMyURL(url:String, window:String ):void { var req:URLRequest=url is String?new URLRequest(url):url; if (! ExternalInterface.available) { navigateToURL(req, window); } else { var strUserAgent:String=String(ExternalInterface.call("function() {return navigator.userAgent;}")).toLowerCase(); if (strUserAgent.indexOf("firefox") != -1 || (strUserAgent.indexOf("msie") != -1 && uint(strUserAgent.substr(strUserAgent.indexOf("msie") + 5, 3)) >= 7)) { ExternalInterface.call("window.open", req.url, window); } else { navigateToURL(req, window); } } } // call the getMyURL using a button mouse event btn_mc.addEventListener(MouseEvent.MOUSE_UP,navClicked); function navClicked(e:MouseEvent):void { trace("clicked"); getMyURL("http://newsourcemedia.com", "_self"); }
AS3 access root from loaded swf
In the root path of your external swf file, defined an object that represent the root path of the container swf.
var rootObj:Object=this.parent.parent.parent as Object;
Get SWF url path and domain name using AS3
In as2 you would use:
trace(_url);
Now in as3 you will have to use loadInfo:
trace(loaderInfo.url);
If you know there is a .com in the domain name, just do a split on the info using “.com”. Now the third item in that array (index 2) should be your domain name.
var swfDomain = loaderInfo.url;
var pathArray = swfDomain.split(“.com”);
trace(pathArray[2]); // should be yourdomain.com if on a web server
Flash AS3 Target Root Path
In ActionScript 2, it was easy to access root, parents, and grandparents. However, in ActionScript 3, we are in for a big surprise when trying to access root the old way like trace(_root.myVar). The AS3 compiler will throw a error the next time you try to use code that looks something like this:
//this code will throw a compiler error
this._root.myMC.x = 10;
If you must access a child of root, you must explicitly tell the compiler, root is a MovieClip! This is called type casting. The following example will work error free.
//this code casts root as MovieClip, and it’s fully legal
MovieClip(this.root).myMC.x=20;
trace(MovieClip(this.root).myVar);
Flash AS3 Set Mask Dynamically
You can set a mask in AS3 using the following actionscript.
function init(){ container_mc.mask = mask_mc; } init();
If you have an alpha gradient mask, you will have to use cacheAsBitmap:
function init(){ container_mc.cacheAsBitmap = true; mask_mc.cacheAsBitmap = true; container_mc.mask = mask_mc; } init();




(5 votes, average: 4.80 out of 5)