Flash upload photo
- Started
- Last post
- 28 Responses
- reluct0
It's without FScommands :)
Here's how you do it:
Make a flash movie called "test.sfw" with a text field. Set the var for the textfield to "name".
Publish it with html and open the html in a text editor.
Change both the src paths to "test.swf?name=joost" and open it in your browser.
The text field should now have joost in it :)
- b34r0
I think reluct got it right.
You need to have (within your main flash movie) a button that will spawn a new browser window. That window will contain the form for uploading. This is a simple html/asp form for browsing for file. Then you'll need to do what reluct said - check file exsistence and forward the image to your intended movie.
Also you may want to consider using some kind of COM object for the upload - it's not that hard to do in pure ASP (opening the image as a stream) - however it does present security risks. Whats to stop me from uploading an activeX object or similar to your server and executing it?
Then, you'll need to check that the JPEG image that is uploaded is *NOT* progressive - cos Flash hates progressive Jpegs.Note that this http://www.impulsedigital.com/id…
is cool and does do a good job - but is *NOT* crossbrowser as it uses the Javascript .click() to simulate a mouse click for the upload.My 2cents on some issues you should be aware of. Hope it helps. : )
- Seph0
Thanks Reluct, I had forgotten you can do that, nice.
- reluct0
np :) Post it here when it's finished. It sounds interesting.
- Seph0
Some handy hints here B34R, the ASP nerd here reckons we need to use a server side app to handle the image and this should reduce security risk that you mentioned. The server app automatically resizes and compresses the uploaded image, I should think it would reject non jpgs at this stage.
Not sure what a COM object is, can you explain in more detail why we would need it.
Thanks a lot
- Seph0
Reluct - I will send you a link by email when the proposal is done. It will only be bare bones functionality at that stage however. Give me a week or so.
- b34r0
Seph - You actually explained the COM object yourself (the server side app). A COM object will allow you do marvellous things Server Side - for example changing/producing a document to a PDF 'on the fly' etc.
There are some good ones here to help you...
http://www.aspupload.com
http://www.aspupload.com/aspjpeg…Hope it helps...
- noneck0
You don't need to use flash 6 to import the jpegs, if you don't want to.
There are numerous apps/scripts that will happily convert a jpeg to a swf, quite nicely too.
Here's an asp one I found in google:
http://chattyfig.figleaf.com/fla…You can also do some *really* crazy stuff with swfs and php if you have the ming library:
http://ming.sourceforge.net/