1

Bonjour,

Je propose ce petit exemple pour montrer les échanges de la donnée entre un fichier SWF et JSP d'une part et SWF et Fichier TXT d'autre part.

On va utiliser JSP donc on va utiliser Tomcat pour ce la copier le dossier "womar2006" dans fichier webapps "C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps" puis exécuter http://127.0.0.1:8080/womar2006/test.swf.

b6zY top
Les étapes à suivre:

1. On prend le paramètre de fichier texte "data.txt" et afficher et tu peux entrer un texte selon votre choix comme tu veux mais tu dois respecter les règle de l’écriture et tu peux écrire avec les balise de html pour la mise en forme du texte.

• "&"+"Your variable name"+"="+"Your variable value"+"&br="
• &womar2006=womar2006<br>Bonjour&br=
• Tu peux modifier le Txt de "Your variable value" à votre choix et tu peux insérer la mise en forme à l'aide des les balises html { <br>, <font>...}.
-1- si tu clic sur le bouton " load text from fichier " --> tu fais affichage appartir du document "data.txt"
-2-bouton " load movie"

2. On va envoyer des paramètres de SWF vers JSP et on fait l'affichage dans le "test2.jsp" et par contre on envoyer des paramètres de JSP vers SWF et on fait affichage dans "test.swf"

• Tu écrire un texte dans la 1 zone texte puis clic sur le bouton "send Parametre vers jsp"
• Le texte affiche dans le "test2.jsp" et tu trouves une autre zone text tu écrire un texte puis bouton "envoyer".
• Il va rediriger vers le fichier test.swf et affiche au place de "Parametre envoyer par JSP" votre text qui tu as écrire.
3. On fait un load d’une image on donnant le sible de l'image(le sible complète avec l’extension)
• Tu entre le sible d'un image comme "test.jpg" dans la zone "cible de votre image" puis clic sur le bouton "load image".
• L’image affiche au coin inférieur du page.


top

--------womar2006@yahoo.fr------------
-------womar2007@gmail.com-----------
-------Skype: womar2006

b6zY

2

3

moi je comprends pas pkoi tu fais pas une requete avc ton loadvars vers ton server pour un transfert de donnee vers ton server avec genre ca :
http://www.adobe.com/support/flash/action_scripts/actionscript_dictionary/actionscript_dictionary434.html

4

oui c'est un exemple comme ca


loadVarsObject .send( url [, target, method ] )

Parameters

loadVarsObject The LoadVars object to upload variables from.

url The URL to upload variables to.

target The browser frame window in which any response will be displayed.

method The " GET " or " POST " method of the HTTP protocol.


Description
Method; sends the variables in the myLoadVars object to the specified URL. All enumerable variables in the myLoadVars object are concatenated into a string in the application/x-www-urlform-encoded format by default, and the string is posted to the URL using the HTTP POST method. This is the same format used by the loadVariables action. The MIME content type sent in the HTTP request headers is the value of myLoadVars.contentType , or the default application/x-www-urlform-encoded. The method " POST " is used unless " GET " is specified.

If the target parameter is specified, the server's response is displayed in the browser frame window named target. If the target parameter is omitted, the server's response is discarded.

This method is similar to the XML.send method of the XML object.