| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|
#1 |
|
Registered User
Join Date: Sep 2004
Posts: 4
|
I am trying to call a .html file with an embedded .swf, from a hyperlink, then pass arguments/values to it that tell it what resources to load.
My approach so far ; //build a new html doc in JavaScript, embed swf myHTML='<HTML>\n'; etc. myHTML+='<EMBED src="myfile.swf"....></EMBED>\n'; //open new window with the html mywindow=window.open(); myDocument=mywindow.document; myDocument.write(myHTML); //finally my attempt to pass the values... myDocument.setVariable("myVar",'strng2') Please help if you see whats wrong or know a better way ...thanks |
|
|
|
|
|
#2 |
|
done
Join Date: Jun 2001
Location: portland, or
Posts: 8,048
|
so if your writing out the entire html doc like this in javascript, then you can grab the url, strip out everything beyond the '?' (if you use get to send variables) then grab they variable value pairs, they should all be separated with '&'.
__________________
tg --- what the hell was i thinking? |
|
|
|
|
|
|
|
|
#3 |
|
done
Join Date: Jun 2001
Location: portland, or
Posts: 8,048
|
oops...
pass them into flash via flashvars. also, don't forget to include the <object> tags in your html, unless you don't want ie to view the page of course.
__________________
tg --- what the hell was i thinking? |
|
|
|
|
|
#4 |
|
Registered User
Join Date: Sep 2004
Posts: 4
|
Thanks a bunch tg. Your info opened up a simpler way to do it(sending, retrieving them via the URL)
JF |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|