Chapter 4. Using JavaScript with Flash for SEO
JavaScript can greatly enhance both the user experience and search engine optimization (SEO) for the Flash content in your websites. Using some third-party JavaScript, you can have an incredible amount of control over what users see when they visit your site without Flash, and you can even create deep links to your applications in any of their states. In this chapter, we’ll look at how to use JavaScript in conjunction with Flash to add these enhancements.[1]
Prerequisite JavaScript Experience
You may be wondering how much JavaScript you’ll need to know to make it through this chapter. Fortunately for those who aren’t familiar with JavaScript, the code we’re going to use is very simple to implement in a site, especially if you’re already familiar with ActionScript.
JavaScript is an ECMAScript language, meaning it’s compliant with certain standards (see http://www.ecma-international.org/publications/standards/Ecma-262.htm). ActionScript is also an ECMAScript language, so it has many similarities to JavaScript. Since ActionScript 3.0 is based on a different ECMAScript version than JavaScript, there are a few important differences between the two languages. The version of ActionScript that most resembles JavaScript is ActionScript 1.0, but if you’re familiar with ActionScript 2.0 or ActionScript 3.0, JavaScript should be pretty easy for you to learn.
A detailed study of JavaScript is beyond the scope of this book. However, as with the other ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access