ActionScript 3.0 :: Controlling The Size Of An Uploaded Art File To Display On Movie?
Mar 16, 2011
I've got the following file reference listener on a file to upload art for display on a flash movie. However, I want this to display only at a certain size. I tried the "easy way", but this ends up sizing down my whole movie. Where should I insert the code to get the uploaded file to show on my flash movie only to a certain height and width? "chip_clip" is the empty movie clip this is being uploaded to:
var file:FileReference = new FileReference();
file.addEventListener(Event.SELECT, fileSelect);
file.addEventListener(Event.COMPLETE, fileComplete);
I am creating a site witch has a gallery page. I first used an instance of the UILoader to load a separate galley swf into the main site. Now while this was fine for all things local, the minute I uploaded to the production site for testing I am left with a site where only some text line of the gallery's xml file. So I tried enclosing the gallery into the main site and am left with the same thing. I've check all the paths to the thumbnails and large files as well as the large and relevant sound files.
Is there a maximum size limit for files being uploaded in Adobe Flex?I am testing it on localhost and can't upload a file of roughly 300MB.Even though I receive the complete event, after I upload the file....I was able to upload a file of roughly 10MB.
I load a movieclip via: on(release){ loadMovieNum("detection.swf", 1); } So I load it in my current timeline on level 1. Now in the detection.swf is a button that has to control the first movie. (that loaded the swf)
I tried: on(release){ _level0_root.nextScene(); } Which did not work. Referencing via _root.nextScene() also, because the loaded swf has its own _root. So how can I control the first movie out of the loaded one?
I have a movie where on the main timeline stage I have placed a movie clip (Clip1) and a dynamic text field. I have a .txt document that contains a variable that will always be a number (Var1).
Currently, the dynamic text field reads Var1 and displays that number. This is great, but I want Var1 to be used in 2 places:
How can I get Clip1 to also read Var1 and, based on the number that is Var1, play a certain frame of Clip1?
I'd like it to go like this: If Var1 is <1000 then play frame1, If Var1 is =1000 and <2000 then play frame2, If Var1 is =2000 and <3000 then play frame3, and so on...
So I'm trying to get sound on my flex application. Then tried to load an swf movie with only audio in it.But when it loads on init(), it loops non-stop.Here's a sample code:
While creating one photo gallery I am facing one problem in controlling the Font Color, Font Size and other characteristics of a text loaded into a text field from an XML File. The name of the text field in question is �my_txt� it loads the title from the xml file attached herewith. how I can control the behavior of the text loaded in that text field.
I have a flash template that I bought and customized with dreamweaver, flash and Coda html editor, the website test PERFECTLY when I test the index.html file, all of the buttons work fine, I have a total of 12 .flv videos and they ALL play back fine, when I play the index.html file, the problem occurs when I upload the files to my godaddy server, 11 of the videos play fine, the whole site is fine, it is one particular .flv file that will not play once it is uploaded to the server. I have changed the orders the video play, renamed the file and changed the html flv path to reflect the name change, I have deleted all the files off my server, refreshed the server logged out and re logged on and uploaded everything again, I have re-encoded the original .mov file to a .flv file again using Adobe media encoder, still nothing, I am wondering why would the index.html play this particular .flv file fine, but once uploaded to the server it will not play, the path is correct I have checked it, if the path were the problem the index.html for that particular file would not play when I test the index.html file before I upload it, but it plays fine until it is uploaded, I am uploading the whole folder on the root, and this particular video file is in a folder with all the rest of the .flv files, I even tried changing the path and putting this particular .flv file in a seperate folder and change the path still nothing.
I've created a couple of little flash movies (for the first time) showing figures merging into one another. I imported the movies into Dreamweaver and when I tested them in my browser, they worked fine. However, now that I've uploaded all the pages/files for my client to look at, the movies don't work. Infact in one case it doesn't even appear.
I have an HTML file which is located in the same folder as my swf movie. I want to be able to display the HTML file in my swf movie using Actionscript3.
i need script and some instructions how to: display my movie file_name in example "movie-1.swf" or just "movie-1" inside of my movie-1.swf in the text field or something ...
it is my movie own file name but not writen directly by me from keyboard but writen by script so if i change file name it will be updated automaticly in the movie after movie is reloaded so file movie-1.swf renamed to movie-2.swf will display text "movie-2swf" or just "movie-2"
I am trying to build an uploader that will take data collected earlier in the form before the upload occurs and then rename the uploaded file with it. I've gotten the upload itself to work, but thus far I have no luck getting any sort of renaming to work, not even by PHP.I tried Loadvars to transfer the variables over and rename it during upload, yet it says "NO" and rejects the post variables when the upload occurs. I even tried loading the variables into an external file and transfering them back to the uploader via cookie, all at the same time. Again it says "NO!", and the file is uploaded as __"filename".jpg. This is my code thus far:
I have a project that requires me to display the waveform for a uploaded sound. The sound is always an MP3, most of the time 22.05 kHz mono, with speech only. The project are written with Flex/ActionScript 3. It's meant to run in the browser, but might also consider converting to AIR if that can help.
All examples I've found and looked at for generating a wave, are either doing some visualization in real time as the sound is playing, or, the most promising, as3soundeditorlib, keeps the wave already generated, but does it very slowly, seemingly using as long time as playing through the audio would've taken.Is there any way to generate the wave faster than real time?
I'm rendering a xps file using flash (no MX or Spark), and I'm running into a sort of 'contradiction' that I'm unable to solve. [Note, that I'm trying to work only in core flash (e.g. Sprite, Shape, etc.), I've already solved (sort of) this issue using Spark.]
The pages of the xps file specify an explicit size. However, the content described (especially paths) in the xps file can sometimes extend outside of this area.
The problem is, I want the parent Sprite to have the size specified by the xps file, for example so scroll bars match the page size (not the sprite size), but in some cases the Sprite is much larger than this.
I've tried recursively going down and scaling everything UP, and then at the end scaling the parent container DOWN. Unfortunately, this causes translation problems with paths, and I assume it can also cause problems with bitmaps, etc.
Without using MX or Spark, is there anything I can do to control the size of the parent Sprite, other than scaling all the children independently?
I am working on an AS3 file for one of my webpages, in Flash it is 660 x 2800 pixels in size, which is relatively large, and to view the entire file contents i need to have a zoom level of 40%! Once publish as an SWF file and uploaded to my webpage, the file appears very small!! I expand the file to as large as possible on the webpage and the file still appears undersized. Obviously I wish it to fill the whole content area.
I'm building a cms and I want users to be able to upload videos but I'm not familiar with video upload & conversion. Is there an example or has anybody coded a solution like this? I heard about ffmpeg but I don't know how to integrate it with asp.net.As simple solution I can make my clients upload flv files but then I would still need to get a screenshot from that fvl.
I then want to load the entire file back into flash as I have some code the analyses it. I have tried
echo $data;
This send what seems to be the first section of the file but as the file can sometimes be 50Mb+, I need all of it. how to get the whole file into Flash?
It will play just fine when I demo it on my own computer but when I upload it to a web server it doesn't work anymore. It shows that there is a Flash object. When I right click on the object it gives me the normal "Zoom In" and "Quality" buttons, but the movie itself doesn't play. And I do have the html file and the swf file in the same folder and it is named movie.swf. There is no other html code in this webpage than the above.
I have followed the XML Video tutorial and everything works fine however Lee says you can use a movie clip to display the contents of the XML file instead of one of Flash's built in components. Is there a way to create your own drop down menu or simple text field?
I ve uploaded flash file with transparent background to my web page. Set background transparency in html code of page. Purpose of this flash is to represent main meny, so it contains few buttons, in up and over stage everything is ok but when i press mouse some strange doted line appears around flash, on click out of flash zone line disappear i want to remove that doted line.
I am currently trying to create an application that allows a user to upload a photo into flash and then manipulate it. I am building it with AS3 and really cannot have the flash player any higher than 9 if possible.So far i have my upload script working using php from a basic html form. This uploads a jpeg to the 'images' folder on the server giving it a unique filename.Once the upload is successful the user is taken to '../upload.php' with the Flash swf on and tells them it has been successful and 'echo's' back "$newname" (variable for the new file name)How can i get this uploaded image on the server into my swf to display in an emptymovieclip with an instance of 'myObject' (currently a picture of a cat). What is the actionscript needed to call the file into my movie?Have come to a complete standstill on i have attached the fla file and also the upload.php file. The code on upload.php is also posted below
Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
iv been having this problem with swf file iv created, it consist of images somewhat like a gallery. when played offline it works smoothly, navigating frame to frame / image by image. iv used AS3 to compose the animations in my flash file. now my problem is when its uploaded online, the swf is shown but once iv clicked on a link to proceed on showing the gallery it lags and continously loop when it should actualy stop on a frame and wait till the next button is clicked to procced to the next image. plus the animation iv added in doesn't seem to working at all.
private var filer:FileReference; protected function button1_clickHandler(event:MouseEvent):void { var fd:String = "Files (*)";
[code]....
And my file looks like this:
[URL]
I need to read the uploaded file and parse it. The problem is that in my e.currentTarget.data.toString(); I get only '1' and not the rest of the String. how to successfully read this entire txt file?
Does anyone know any good tutoriols on how to create a "slideshow" or "playlist" in ActionScript3? The slide can be either a simple picture, a soundfile or a video. I want to be able to jump back and forth in the slideshow/playlist, and also see how long a slide will be shown. The playlist will be loaded from a pre-defined XML-file.
I am in the middle of trying to create an swf that allows the user to upload an image into the flash file and manipulate it in several ways using actionscript 3 and flash cs4. (ideally if possible keeping the flash player needed at 9 or lower).I have solved most of the photo editing side, but am having trouble uploading any photo into the flash file. I have looked into the 'getfile reference' class and also the 'oncompletedata' but havent got it working. Can anyone help? I need the user to click on the upload button on frame one which will upload the file to the server and display it on frame 2 in the empty_mc (instance of myObject) Currently i have a random jpeg image in its place.
Originally i intended to use an html form and php upload script to do all the uploading then send the url link into flash but again cannot come up with a way for this.This successfully uploads my image onto the server in the 'images' folder but how do i get this into my swf?
I have just uploaded my site for a recent project submission and coded my own preloader for it.The problem is that when I play the file (swf) locally it works correctly but when uploaded onto the internet the variable % is not loaded so says: loading... NaN%. The thing is that it works correctly other then that,when it is fully loaded the text and the preloader disappears as instructed. It just doesn't put a % into the percentage dynamic text box (which has instance name percentage and variable namepercentage).That is the site and this is the code for the preloader:
I have a project that will have a video upload capability. The thing with this is when the user uploads it has to of course play in the custom Flash player - the only way for that to happen, to my knowledge, is if that video is in FLV format. how to convert the uploaded video file to FLV (serverside not client).
I'm using SWFUpload to upload images without reloading the page (with a fancy progressbar too), this works fine when I'm on localhost (Wamp server), but it goes nuts when I try to do so on my real linux server (which is the only possible flag as far as I could see), it's running Apache2 and PHP5. As I said the front-end is fine (apart maybe from the fact it's flash).The back-end code is as follows:
The only error that I get is from $_FILES['Filedata']['error'] = 3, 'Only part of the file was uploaded'. The destination directory does have 777 permission and you can see I made the required checks. It simply will not work, I have no idea why. Also, the files I tried uploading had no spaces in the filename, so that shouldn't fit under the issue 206 with SWFUpload.As far as I can tell it can be either due to the front-end SWFUpload or back-end server configuration.
P.S. no need to mention security, this is only allowed to be used by the server admin with external access anyhow, plus there's the front-end limitation on the files he can select (images). There was no point securing it further.