lundi 3 avril 2017

How can I embed a javascript in my AS3 (AIR) code?

There is this website : http://ift.tt/2nDSueG that allow us to copy/paste their forecast script in order to embed it where we want.

Here's the script :

  <script type="text/javascript" 
src="http://ift.tt/2nVBQd6">
    </script>
    <noscript>
    <a rel='nofollow' href='http://ift.tt/2nDwxfU'>
    Wind forecast for Nouméa Magenta Aéroport
    </a> provided by 
    <a rel='nofollow' 
    href='http://ift.tt/2nVzQ4T'>windfinder.com
    </a>
    </noscript> 

I've got an AIR app (as3) and I'd like to embed and display this widget.

Is there a way to do so ? (I suppose with externall_interface but don't know how to do so...)

What I did for now :

1-Copy/paste the javascript code into a .js file. 2- Create, in the same folder, a .fla file with as3 code.

So how could I call the js file with AS3 ?

Thx

Aucun commentaire:

Enregistrer un commentaire