dcsimg
A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: problem passing variables via URL to Flash, (only in IE?!?)

Hybrid View

  1. #1
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36

    problem passing variables via URL to Flash, (only in IE?!?)

    I'm using MX2004, with the usual javascript code in my HTML:

    Code:
    <script language="JavaScript">
    document.write ('<OBJECT classid="clsid:27CDB6E-AE6D-11cf-96B8-444553540000" '
    +'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" '
    +'WIDTH=820 HEIGHT=1700> <PARAM NAME=movie VALUE="drawtesting_syllabi.swf'+document.location.search+'">'
    +'<PARAM NAME=quality VALUE=high>'
    +'<EMBED src="drawtesting_syllabi.swf' +document.location.search+'" '
    +'quality=high  WIDTH=820 HEIGHT=1700 '
    +'TYPE="application/x-shockwave-flash"></EMBED></OBJECT>')
    </script>
    This works just fine in Netscape and Mozilla... the link sends variables to the new webpage, and my SWF embedded therein receives them just fine. But when I do this in IE, it doesn't work... no variables are received. (And I swear this was working when I did it last week.)

    I've tried it on several machines, too. Any ideas? Is there some IE javascript setting I don't know about?

  2. #2
    Senior Member jbum's Avatar
    Join Date
    Feb 2004
    Location
    Los Angeles
    Posts
    2,920
    You seem to be adding something to the .swf filename without an intervening '?'. The usual syntax for passing variable names is

    "filename.swf?param1=val&param2=val"

    What does document.location.search contain?

  3. #3
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36
    I'm passing the variables to the HTML page that contains the above javascript. I admittedly don't understand JS well enough to know all of what that code means, but from other posts on this board I understand that is its point... to pass to Flash the variables tacked onto the URL of the HTML page.

    It's working as advertised with Mozilla and Netscape, but not with IE6.

  4. #4
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36
    *biz-ump*

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center