Embed/Object Flash/Java

Associate
Joined
15 Nov 2010
Posts
437
Location
Tampa
Hi,

I'm trying to find out the most compatible way of embedding flash and java applets, for a client facing site, so it needs cross browser compatibility, but obs I can offer other browsers different solutions.

Valid HTML5 too.

<embed> or <object> is the question really?
 
The Google SWF object allows for flash players to be embedded in 2 ways - static and dynamically.

I suggets you look at the dynamic way (half way down the page linked) which is javascript based and does away with conditional statements.
 
There is no standard non-javascript way. It would be buggy as hell

Use the swfObject static publishing method

The static publishing method embeds both Flash content and alternative content using standards compliant markup, and uses JavaScript to resolve the issues that markup alone cannot

The advantages of the static publishing method are:

The actual authoring of standards compliant markup is promoted
Best embed performance
The mechanism of embedding Flash content does not rely on a scripting language, so your Flash content can reach a significant bigger audience:
If you have the Flash plug-in installed, but have JavaScript disabled or a use a browser that doesn't support JavaScript, you will still be able to see your Flash content
Flash will now also run on a device like Sony PSP, which has very poor JavaScript support
Automated tools like RSS readers are able to pick up Flash content

Is it purely the conditional statements which are putting you off?
 
Adobe actually ship swfObject 2 with their Flex SDK and is part of the default page templates in Flash Builder, it really is the best way of doing this.
 
The thing that is putting me off is using a third party app. I can't do it for this project. And conditional statements wouldn't go down too well in this, since they are effectively a HTML hack.

I really only need to know how the best, current, in-form way to do it using either embed or object tags.
 
Back
Top Bottom