Importer HTML, SWF, PHP with IFRAME and Javascript

 

This example was originally created by gypsytrader
I have just adapted to French and added a PHP script.
Click to see animation
Download zip file ⇒ 

All right, I read on swish-france forum many folks did not understand, and were unable to adapt to their purpose.
Although the reading of caustic comments about a work, which, I repeat, isn't mine, I gonna try to give some explanations.
First, let's remind what is IFRAME : floating frame which can be anywhere within a standard HTML document in Internet Explorer, but also accept WIDTH and HEIGHT and standard HSPACE, VSPACE and ALIGN attributes, to set the display size and alignment of the frame within the document.

Let's take a look at index.html :
Dans la partie Javascript du début, vous trouvez une fonction nommée function Example1_DoFSCommand(command,args)
This function (except part of code inside) has been generated by SwishMax whether you use the swish function fscommand in a script, to run some user's JavaScript ( not the usual alert, prompt, ... ).
Of course, you 'll get it while exporting HTML+SWF.
You also can see the name of the function begins as the SWI file ( Example1 here for instance )
Switch directs some user-defined Javascript functions, to be specific : maximize, validate, iframeCommand.
This last function handles arguments to run other functions.
You usually shouldn't modify them.

Run Example.swi in Swishmax and take a look at scripts.
In scene preload, you 'll find out definitions of global functions opened to all scenes, for instance : iframeResize, iframeHide, iframeDelete, iframeLoad.
These functions are calling fscommand("iframeCommand",..... with some arguments as setHW, setTL, delete, setContent, that what's make Javascript functions iframeSize(args), iframeMove(args), iframeDelete(args), iframeSetup(args) carrying out.
Same here for fscommand("validate") which calls function validate().

n the other scenes, you 'll find out callback to the global functions defined in scene preload.

OK, it's enough to say. You 'd normally be able to adapt to your work ... except whether you are a newbye. A few things to change. It's up to you.

 


Si vous aimez le site

 

Select a language if you need :


Page chargée en 0.002 sec.

Dernière Modification : Mer 25 Janvier 2017 8:56
Copyright © 1999-2017 Jean-Paul Molina Tous droits réservés.

to Google