Hi im looking for some help- any is appreciated. Page has a simple include like this.. <?PHP include('header.php'); ?> I want it to detect if browser has flash.. And replace the above include with a command that does this: If Browser DOES support flash- <?PHP include('header.php'); ?> ELSE- <?PHP include('No-Flash-header.php'); ?> Basically Browsers that don't support flash will see the include designed for Non-Flash browsers. Thanks for any help
PHP is a server-side language and afaik it doesn't support checking whether the browser supports flash or not. Use swfObject instead -> (http://code.google.com/p/swfobject/) Here is a pretty straightforward tutorial on beginner's usage of this javascript library - http://www.pixelmill.com/support/support_article.aspx?ArticleID=kb101619 Basically what you do after you include the .js file to your page, you set some parameters (flash file, dimensions, other variables you might want to use) and make a div with a specific id. You put your alternative content in that div and after all the code you add a simple javascript command telling swfObject that the div with that id has the content that should be displayed if flash is not supported by the browser and that's pretty much it.