[SWFObject] Seperate Stylesheet for HTML and Flash

DL dl.lists at ntlworld.com
Tue Oct 31 13:55:28 PST 2006


On 31 Oct 2006 at 14:02, Thomas Lauck wrote:

> My problem is this: I have a fullscreen flash site, therefore I have  
> my overflow content hidden in my CSS.  If a user does not have flash,  
> no scrollbars appear (because overflow is hidden).  My logic to solve  
> this is to add a function to SWFobject so that when Flash is not  
> recognized that it disables the "Flash" stylesheet and replaces it  
> with the "HTML" one.

If I understand correctly ..

note that when there is no Flash viewer installed, SWFObject displays the div content by 
default.  See examples in SWFObject download.

So perhaps you could nest an iframe inside this div, pointing to a default full HTML page 
which will display HTML content in lieu of Flash.  Classes defined in your CSS sylesheet.

<div class="flashcontent" id="flashcontent">
<iframe class="htmlcontent" id="htmlcontent" name="htmlcontent" 
src="my_default_html_page.html">
</iframe>
</div>

....

For more complex mixing of HTML and Flash you might look at Yahoo UI.

http://developer.yahoo.com/yui/

This works nicely with SWFObject writing Flash into the YUI containers.

The YUI API abstracts the javascript functions.

Downside is you have several more *.js and *.css files to import.


DL

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.deconcept.com/pipermail/swfobject-deconcept.com/attachments/20061031/34b123ba/attachment-0005.htm>


More information about the Swfobject mailing list