Time2Dine.co.nz is Online Restaurant Booking
 
 New Zealand Restaurants Forum
Restaurant Forum | Contact Time2Dine | Book Online & Save | About Time2Dine

Go Back   New Zealand Restaurants & Food Forum > Search Engine Optimisation > HTML & Javascript Howtos
Register

Reply
 
LinkBack Thread Tools
  #1  
Old 2nd Nov 10, 03:39 AM
Junior Reviewer
 
Join Date: Nov 2010
Posts: 1
fzgdine is on a distinguished road
Default FileReference via ExternalInterface

I am creating a custom upload box like <input type="file"> by integrating Flash and JavaScript.

What happens is, when user clicks an HTML button or link, Flash should display browse for file dialog box (FileReference). For that, I am calling a function in ActionScript from a function in page's JavaScript using ExternalInterface.

But it doesn't work, the dialog is not displayed. i.e. The AS function is called but myFileReference.browse() returns False.

It works if called from AS function, i.e. click event of a Flash button. But when the same function is called from JavaScript integration, it fails.

Any solution? I've already tried setting the param "allowScriptAccess" to "always" but no avail.

I've attaching an example, please run it from some web server.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



Powered by: vBulletin Copyright ©2000 -2012, Jelsoft Enterprises Limited.
Search Engine Friendly URLs by vBSEO 3.2.0
© 2010 Time2Dine