Skip navigation
Currently Being Moderated

store data in backend with flash & AS3

Jun 1, 2012 3:28 AM

hi friends,

 

Greetings! Actually iam doing an elearning application, while reading our flash screen, student has to pass their comments to the instructor, it will store in data base and continue reading same screen. if i use post it will navigate to another aspx screen this will last the student where they read. pls advice me...how can i do this? is there any way to store data in db back end direct..?

 

Thanks in advance..

 

Regards,

 

Syed

 
Replies
  • kglad
    62,108 posts
    Jul 21, 2002
    Currently Being Moderated
    Jun 1, 2012 6:04 AM   in reply to rahimhaji

    yes, you can use the as3 urlLoader() class to post variables/values to server-side script (like php) which then adds the data to your db.

     
    |
    Mark as:
  • kglad
    62,108 posts
    Jul 21, 2002
    Currently Being Moderated
    Jun 1, 2012 6:34 AM   in reply to rahimhaji

    don't use navigateToURL(), use urlLoader().  it won't open another browser window.

     
    |
    Mark as:
  • kglad
    62,108 posts
    Jul 21, 2002
    Currently Being Moderated
    Sep 17, 2012 5:57 AM   in reply to rahimhaji

    you can use the javascript onunload method to detect when users close that window and you can use the actionscript externalinterface class to communicate between javascript and actionscript.

     
    |
    Mark as:
  • kglad
    62,108 posts
    Jul 21, 2002
    Currently Being Moderated
    Sep 18, 2012 6:37 AM   in reply to rahimhaji

    if you want so pass 'ind' to show_alert() on loading and reloading, you can use:

     

    <body bgcolor="#ffffff" onload="show_alert('ind');" onUnload="show_alert('ind');">

     
    |
    Mark as:
  • kglad
    62,108 posts
    Jul 21, 2002
    Currently Being Moderated
    Sep 18, 2012 10:50 PM   in reply to rahimhaji

    call a different javascript function that uses the callback method of the externalinterface class.  the help files have sample code.

     

    note: use the embedding html shown (or swfobject) to embed your swf.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points