Results 1 to 4 of 4

Thread: linking to a swf file

  1. #1
    Join Date
    May 2008
    Posts
    2
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default linking to a swf file

    I am trying to link text from Dreamweaver to display a swf file. Can anyone help?

  2. #2
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    You can't link to a swf file like you would to another page. You actually have to embed the swf into another page and then link to the that page.

    For embedding Flash, I recommend SWFObject 2.0

  3. The Following User Says Thank You to Medyman For This Useful Post:

    web_mel (05-07-2008)

  4. #3
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    29,127
    Thanks
    44
    Thanked 3,228 Times in 3,189 Posts
    Blog Entries
    12

    Default

    Medyman is basically right in principle. The technically valid method to use is an object tag or an object tag pair, though many still prefer the deprecated object/embed tag pair, or just the deprecated embed tag. And there are various scripts around to do the 'heavy lifting' of these various methods for you. In fact, using certain types of javascript scripts (preferably, in most cases, with a non-javascript fall back) is the only way to avoid 'Click to Activate' in IE and Opera for Flash on a web page. However, if the swf doesn't require flashVars you can link directly to it and most browsers with the later versions of the Flash plug in will play it:

    HTML Code:
    <a href="some.swf">Some Flash!</a>
    But you will have no design control over how the swf is displayed, and your users will need to use either the back button, the address bar, or other methods of their browser to navigate away from the swf unless it has navigational functions built into it. You can even target it to an iframe on your page and many swf files will work out fine used in that manner, but it is not recommended.
    Last edited by jscheuer1; 05-02-2008 at 08:52 AM. Reason: punctuation
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  5. The Following User Says Thank You to jscheuer1 For This Useful Post:

    web_mel (05-07-2008)

  6. #4
    Join Date
    May 2008
    Posts
    2
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default

    Thanks for the help!

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •