Silverlight app uses Flash to work :)

I installed google chrome some time back. I would reserve my comments about the browser for a different post, but the my favorite feature is the task manager. Today, someone forwarded me the Windows Ads campaigns page, primarily for the I am a PC campaign (which uses Flash video 🙂 ).

I went to see the Bill Gates-Seinfeld campaign. You probably wont be able to see it as you don’t Silverlight or it is not supported for your browser/OS. Don’t bother installing, it is much easier to catch the videos on youTube (Shoe Circus | New Family).

Anyway, I was on the page and i see this…

Hmm.. Flash Player in a Silverlight page? I went on a right click spree and couldnt find it. Then i check out the embed tag on the video-bar and here’s what i get…

Is MS loading a SWF within Silverlight and conning people?? I decided to check it out. I embed the code into an html and ran it and i get this…

I still don’t know if my initial hypothesis was right, though the pre-loading suggests that the soapbox player is done in Flex. Next step was to check out the DOM to see where Flash was on the page. Thanks to Firebug, this was easy work. Here’s what I found (click the image to see a bigger version)

There is a div in the page called clipboardPlaceHolder. This contains a faceless swf that is used to access the system clipboard to copy the embed code into the system clipboard. I did some googling and found that Silverlight does a sloppy job with Clipboard access. There’s something in Silverlight that can access clipboard, but it only works on IE ;). Here’s the thread from the Silverlight forum.

Yes. This script doesn’t work in non-IE browsers.

Please read the following links if you wonder why it doesn’t work. .

* http://www.mozilla.org/editor/midasdemo/securityprefs.html
* IE Clipboard Stealing

The best solution that I have so far is “Using Flash clipboard”. If you want to implement this in your Silverlight, you can get the swf file…

So much for the multi-browser claim. It seems to me that they are trying to show as if Silverlight has capabilities that it actually does not… What next?

Advertisements

15 Responses to Silverlight app uses Flash to work :)

  1. srinivasannam says:

    Thanks for this very nice & interesting exploration Raghu !

  2. Gaspy says:

    If I read correctly, it’s not their fault.
    They are using a flash trick to overcome a the clipboard limitations in Firefox and other browsers. In firefox, javascript cannot access the clipboard by default. In flash, there’s the setClipboard thing.

    It’s possible that Silverlight relies on the host browser to do some of the stuff, so if clipboard functionality is disabled in Firefox, it’s also disabled in Silverlight.

    I’m no fan of Silverlight but this is no big deal.

  3. Tink says:

    LOL man thats a great find!

  4. gmurnock says:

    That is Priceless! Great find!

  5. […] would like to use Flash under the hood! Well a Flex Evangalist says so in his blog entry titled: Silverlight app uses Flash to work . Why not conduct your own research and find out? Also, is leveraging a well established video […]

  6. Scott Barnes says:

    This is simply work-around due to a security limitation in firefox. Silverlight 2 is currently in it’s second round of beta, so all things beta apply here.

    We’re actively working to ensure Silverlight remains secure and rushing implementations like clipboard access are something we also take seriously.

    eg: Flash has clipboard access right? yet its also got issues with this very feature? (so damned if you do, damned if you don’t applies here).

    http://www.insideria.com/2008/09/adobe-flash-clipboard-hack.html


    Scott Barnes
    Rich Platforms Product Manager
    Microsoft.

  7. chris says:

    seems like the way to test this would be to install silverlight but not flash, or to install the debug version of flash.

  8. LOL !!!

    That page shows me Get Silverlight and plays a Flash version of the video .. when I do have Silverlight installed on my Mac .. both on FF3 and Safari

    Mrinal

  9. creynders says:

    yep, you’re right. There’s another swf which gets loaded: videoPlayer-gates-seinfeld.swf
    (from http://www.microsoft.com/Framework/flash/VideoPlayer so they’re not exactly making a secret about it 🙂 )
    which in turn loads the bill-jerry.flv.
    So they DO use a flash video player.

  10. […] Comment on Silverlight app uses Flash to work by creynders […]

  11. […] Silverlight app uses Flash to workClever work-around to a problem that needed to be solved. […]

  12. Burke says:

    Its no secret that Silverlight has a LONG way to go to catch up to Flex – if in fact it ever does. But lets not fault MS for doing what they have to do to get their technology to work and then fill in the gaps.

    Should they have displayed a banner saying “We are using Flash on this page and we didn’t write Flash”?

    That would have been an appropriate disclaimer, but slightly rediculous.

    Either way – GREAT find. It’s important to note that MS also promotes the use of javascript in ASP.NET instead of vbscript. Javascript is just better – so thats what we use.

  13. sundeep says:

    Great work Raghu.
    But now Microsoft will change Silverlight not to use Flash……..

  14. […] Silverlight application uses Flash to work! 26 11 2008 And now the much hyped Silverlight is/trying to use flash to work for them! There is a nice post relating to. Read here […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s