Well, I've trimmed down the javascript code to:

function sendToFlash(txt) {
  var swf = document.getElementById("NewFlashpreviewer");
  swf.sendTextToFlash(txt);
}

My embed code looks like this:

var attributes = { id:"NewFlashpreviewer", name:"NewFlashpreviewer" };
swfobject.embedSWF("Designer2.swf", "NewFlashpreviewer", "850", "350",
"9.0.0" , "/swfobject/expressInstall.swf", flashvars, params,
attributes);

My HTML code looks like this:

<div id="NewFlashpreviewer">stuff here</div>

Still Fire Fox does not work, but IE works (all versions I can find to
test).

Although I'm not a JS or Flash expert, I have spent hours on end
trying to understand why I'm having issues - only with FF.  Seems to
me all my bases are covered.

Beer offer still stands.

Thanks for any help.





On Mar 9, 8:15 pm, Aran Rhee <[email protected]> wrote:
> Len.
>
> I would have a review of the communication example 
> page.http://www.bobbyvandersluis.com/swfobject/testsuite_2_2/test_dynamic_...
>
> It has some good code to:
>
> 1) ensure you have a proper DOM ID to talk to
> 2) getting the DOM reference to the SWF
> 3) check if the method is actually available on the SWF before calling
>
> *You should make sure you set the id and name attributes when calling
>
> Here is an extended example showing how to the use callback function to gain
> the dom reference to the 
> swf:http://www.bobbyvandersluis.com/swfobject/testsuite_2_2/test_dynamic_...
>
> Here is a good tut explaining a bit 
> more:http://learnswfobject.com/advanced-topics/external-interface/
>
> If it works after reading / implementing this, then the beer will have to be
> virtual as I am in Australia :)
>
> Cheers,
> Aran
>
>
>
> On Wed, Mar 10, 2010 at 8:24 AM, Len <[email protected]> wrote:
> > I'm neither a flash or java script expert, but I've been playing with
> > a project that is just making me nuts.
>
> > Simple enough in concept, I have input fields on a HTML form, that
> > when changed need to pass the new value into my flash file.
>
> > I am using this to imbed the flash inside the <head> tags of my html
> > page:
>
> > swfobject.embedSWF("Designer2.swf", "NewFlashpreviewer", "850", "350",
> > "9.0.0" , "/swfobject/expressInstall.swf", flashvars, params,
> > attributes);
>
> > Inside the flash I use:
>
> > import flash.external.ExternalInterface;
> > var eiEnabled:Boolean = ExternalInterface.addCallback(sendTextToFlash,
> > getTextFromJavaScript);
>
> > Back on my html page I have the functions:
>
> > function getFlashMovie(movieName) {
> >        var isIE = navigator.appName.indexOf("Microsoft") != -1;   return
> > (isIE) ? window[movieName] : document[movieName];
> > }
> > function sendToFlash(txt) {
> >        getFlashMovie("NewFlashpreviewer").sendTextToFlash(txt);
> > }
>
> > Then it is just a simple onChange event that calls
> > sendToFlash(this.value);
>
> > Here's the issue, this all works fine with IE 8 (in compatability mode
> > or not)... but it don't work at all with FireFox version 3.5.8
>
> > Free beer for anyone has a clue what the issue is or (more likely)
> > what it is I'm doing wrong.
>
> > Thanks for any help.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "SWFObject" group.
> > To post to this group, send email to [email protected].
> > To unsubscribe from this group, send email to
> > [email protected]<swfobject%2bunsubscr...@googlegroups­.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/swfobject?hl=en.- Hide quoted text -
>
> - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
"SWFObject" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en.

Reply via email to