In my movie i have a link button with following, simple, function creating a link:
[Code]...
lately i've associated a class file (.as) to my movie and immediately after, when publishing the movie i got the following error message: 1046: Type was not found or was not a compile-time constant: URLRequest. as well as a couple of other related error messages: 1180: Call to a possibly undefined method URLRequest. 1180: Call to a possibly undefined method navigateToURL. when i remove the link to the class file, the problem goes away. also, i have checked the class file for mentioning of "URLRequest" and nothing is there.
what want to make is let people submit a URL and then show the image on the stage .. so i went an wrote my code but it doesn't work as i expected .. here is the code
var myurl:String ; // a var to load the text in it var reques:URLRequest = new URLRequest (myurl) ; // the urlrequest (i know that this only accept strings but what to do !!) var loader:Loader = new Loader(); // the loader
at the moment I've got a (perhaps) requirement for specifying precedence to certain queries within a movie, which will be dealing with the upload of assets through flash to a php backend.
Does anyone have any info, or maybe a pointer in the right direction with regards to how flash deals with the internal URLRequest stack. If that's even how it works.
I may be vastly over simplifying the way flash works, but the only analogy I have is my own exploration into protoyping an AJAX query stack a couple of years ago, where you'd be able to alter the stack ordering depending on request priority as it were.
I'm working on a little game/quiz where the user has to get 8 or more questions correct.If they get 8 or more correct and hit submit, their scores will be sent to a server. I don't have the server info yet, but I believe I'm pretty close to solving this on the flash end of things, as far as sending out the url with the total number correct appended.I'm getting the following error.
Code: TypeError: Error #1034: Type Coercion failed: cannot convert "http://www.website.com/complete.asp?13" to flash.net.URLRequest.
So basically I have this map. On this map I have points, and when you click on these points it goes to a URL.The code setup is as follows:
Arrays to define the movieclip locations and another for the urls (this one is an associative array). I then create a function loop to make an event listener for each point. When the point is clicked it will run another function that handles the URLs. The URL function is to grab the target point that has been click, use the url array type to find the key, and then throw it in to the URLRequest.
So far I have this code:
var places:Array = new Array(); places = [ map.paulsens, map.paraburdoo, map.plutonic, map.wiluna, map.gwalia, map.wallaby, map.sunrise, map.moora, map.marvel, map.flyingFox, map.ernest, map.rosebery,
[code]....
So it's obvious to me that the openLink(); function isn't doing what I want it to. I can kind of guess because event.target isn't being turned in to a string or not pulling the array's type?
I have a music player that loads 2 files, and then plays the 2 files on 2 separate soundchannels. I need to test to see if the 2nd music file is able to load, and then let the play controls check for this to determine how many sound channels to play.
how to pass a variable from FLASH to PHP?I'm trying to upload an image through the URLRequest and pass a unique name for each file.( I want to store the name elsewhere and need flash to know the name of the file.)
Since I'm using the request.data for the ByteArray of the image, I read that I can't use the URLVariables to pass any other variables.
It is almost working, except for the filename.AS3 function calling the request and query string:
Code: function uploadTheImage(GuidName:String):void { //create image var stage_snapshot:BitmapData = new BitmapData(imgprev.width, imgprev.height); stage_snapshot.draw(imgprev);
if website is opened as [URL] so this URL works fine- URLRequest("[URL]"); BUT if opened without WWW as [URL], this URL doesn't work. If I change link in url without www than works. HOW TO CHANGE SCRIPT OR TO ADD URL TO MAKE THIS CONTACT FORM WORK WITH WWW AND WITHOUT
I'm new to AS3 and I'm having a problem with an extended class that uses a URLRequest. I have a basic class called 'imageLoader' that I use for loading in external images
I'm loading images via a URLRequest and Loader classes and I want to manage the image when the request is complete. The example below doesn't fire the event when it is complete. The same code would work find for a URLLoader, but not a Loader object. Basically the image loads and the event listener is never fired. Can anyone tell me how to get an event to fire when Loader finishes loading an image.
var imageReq:URLRequest = new URLRequest("http://www.google.com/images/nav_logo29.png"); var imageLoader:Loader = new Loader();
im using flash with AS3 and i use the instruction var myTween:Tween = new Tween(waves, "y", Strong.easeOut, waves.y, puntop, 3, true); for making simple animations, the think is that when i call a URLRequest the animation just stop and freeze.
var xmlURLLoader:URLLoader = new URLLoader(); var xmlURLRequest:URLRequest = new URLRequest();
I am taking some old AS code and trying to plug it into Flash Builder. I am getting a "Type not found."warning with those variable declarations. Does anyone know which package to import?
Need to find a way to send a delete method from Flash Player (Flex). Currently it's not done by default (except for from AIR), but I am sure someone has augmented the URLRequestHeader to get it to work properly. I've tried this, it isn't working:
I will use the URLRequest to upload the modified image in Flex. It works fine. However, I need to add Content-Length as a URLRequestHeader for the moment, and I get error 2096. Then, I know that this header is not allowed.
Update: According to adobe's documentation: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/net/URLRequestHeader.html[code].....
How ever when I keep getting back "error:empty request". I emailed the site owner and he said that my program may be dropping the data during redirects.[URL]
I'm having a little trouble with the 3. I'm trying to use a URLRequest to get login information from the mySql server. It works great when I try to log in, but if anyone else from outside my network tries to log in, it just hangs. I'm on port 8080 using localhost. I've even tried changing everything to my IP address instead of localhost and allowing my tester to try, but it still hangs.
How can I reorganise the code below so the trace commands output i for each element in the photourls array and not just the last element? In a 6 element array, the trace(i); line outputs 5,5,5,5,5,5 rather than 0,1,2,3,4,5.
I am working on a flash website that loads live inventory data from a public csv file publish by google docs. the csv file is located at a public address on google docs server:[URL].. I am using a URLloader and URLrequest within my flash movie to grab this data and assign it to different variables.
It works great when I preview the movie in flash. However, when I go to publish the movie and preview the html file its loaded into in dreamweaver, I get a security warning from adobe flash player: Adobe Flash Player has stopped a potentially unsafe operation
I went ahead and published the html file that contains the swf file to the web, and when I go to my site, I don't even get the flash player warning; it just sits there like its trying to load the URLrequest and never completes.
I understand that flash player has a security measures that prevents flash files from accessing files outside of the server directory that the swf file is published to. I know you can create policy xml files to tell flash it's okay to load the data, but those policy files have to be located on the public server from which the data is being grabbed. But it's not like I can waltz on to google's servers a stick a policy file in there!
Is there any way to tell the flash player it's okay to load this data without getting that security error? I can't have the end user having to go into their flash settings and adding the location manually. I just need it to work without the security warning.
Is there another method of loading data from an external server without tripping up flash player security? aka, something other than URLloader and URLrequest?
var xmlLoaderA:URLLoader = new URLLoader(); xmlLoaderA.addEventListener(Event.COMPLETE, LoadSomething); xmlLoaderA.load(new URLRequest("my url"));[code]....
now imagine that the loading of the file is completed and we are in the "LoadSomething" function. How can we trace "my url" in this function? In another word I want to wite this action:
trace(Command);
and I want "my url" string in output.But I dont know what is the Command.
During development I have to test using several different hosts. It is a pain to have to change the IP address everywhere I use navigateToURL or in an mx:HTTPService. I would like to set a var with the IP... public var hostIP:String = "192.168.1.100"; Then later I instead of doing...
working my way through some tuts, and have set up WAMP. Trying to send some vars from AS3 to PHP to update a mtySQL table.My issue is that the php file does not seem to be receiving the variable info from flash, why not?
Here is the AS code
Code: submit_btn.addEventListener(MouseEvent.CLICK,onClickSubmit) function onClickSubmit(event:MouseEvent):void { var loader : URLLoader = new URLLoader();
[code]....
The PHP works cos when I run it from a browser $sd3 updates the database field to 78.This the output of the 'trace' statements
I cannot ascertain why the code for one set of navigation buttons I've created works, but similar code does not. The code is rather lengthy, but I've pulled out the salient components to see if the Interwebs could help.
Here's the script that IS working:
Listener code:
Code: cswordbutton.addEventListener(MouseEvent.CLICK,fetchcswordassets); And the function code that goes with it:
Code: function fetchcswordassets(e:MouseEvent):void{ var url:String = "knowntomeURL";
[Code].....
1) All of the actions are in a separate layer in the first frame;
2) There is only one scene;
3) I've given the same button a different instance name in many cases, to coincide with different expectations (URLs).
public class TextboxXML extends Sprite { [...] //XML[code]....
i want to get the xml-data. the xml will be generatet out of a php-function.testing it out of flash by "testing the movie" (apple+return), the php will be parsed and it works. when i test it on my lokal server, the same smf i mean, nothing happens.
I have an xml file which contains multiple products each with their corresponding background image, foreground image, text and website. The LoadXML class loads this xml file and creates an array of each image, text and website. The Main class then loads each image from the array of background images in the method onBackgrLoad(). This is done through the use of a for loop which loops through the array of backgrounds (called hintergrund[]) and loads each one in turn. On tracing hintergrund[] I sucessfully receive a string of all the different background image paths. However when I examine the backgrRequest and backgrLoader they both contain null. The images therefore dont appear on stage but neither does an error message appear! The same thing happens for onImageLoad (this should load the foreground image) and onTextLoad.
public class Main extends Sprite { //____________________________________________________________________________Vars : Newly
fla files which is calling default page . but it's not able to find the default page.. my default.aspx page is in root directory ,and my fla file is in ../capture/image.fla . here is my code
can I make role based authorization when sending requests to an ASP.NET MVC backend system. I am calling action methods and expecting JSON results, however, some action methods are decorated with the [Authorize] attribute, others require some role privileges to be present. I certainly hope that passing authorization data with every request is possible