Chapter 35. Deploying Flash on the Web

Introduction

In this chapter

  • Embedding Flash in a web page

  • Using SWFObject

  • Passing variables to Flash

  • Using Express Install

Programming your creation in ActionScript 3.0 is the first, and most important, step. Any successful project must also deploy it correctly. In most cases, Flash content is seen on the World Wide Web, within your web browser. There are other possibilities for your content, such as a screensaver or a kiosk, that typically require third‐party tools to implement. This chapter covers the important issues in preparing your Flash content for deployment over the Web.

Embedding Flash in a Page

If you are developing Flash content for the Web, at some point you will have to embed your SWF in an [X]HTML page. This process sounds like it should be a stroll in the park, but unfortunately the park is strewn with land mines.

Rendering Flash in a web page requires the Flash Player plug‐in. And despite the fact that browsers have been around for many years, there are still differences in plug‐in architectures and the HTML that should be used to embed them. To wit, Internet Explorer uses ActiveX controls, and Mozilla browsers use the NSPlugin architecture. Different tags have been used to embed content: the <embed> tag and the <object> tag. Browsers even implement these tags in slightly different ways. To complicate matters, writing valid [X]HTML is desirable, and often required, but the <embed> tag is not valid in HTML 4 or XHTML 1. To make things ...

Get ActionScript™ 3.0 Bible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.