Professional :: LoadVariablesNum In Different Directory?
Oct 19, 2010(and wondering if it's somethin completely unrelated that i'm missing as i can't see how this would have any effect on loadVariablesNum!)
View 3 Replies(and wondering if it's somethin completely unrelated that i'm missing as i can't see how this would have any effect on loadVariablesNum!)
View 3 RepliesGreetings: I've used this method many times in the past to create an email form in a movie clip with a "send button" that accesses a perl, cgi script to email text input fields. It worked fine in past versions of Flash, but now I'm using Flash CS3 (v9.0, AS 2.0). I've tried 3 different cgi scripts I found online for this purpose and am sure the configurations for sendmail server & perl bins, etc are correct. All of the other "if" and "else" statements on the button work fine. But I can see a Safari (browser) error message saying POST was not used, but clearly it is. I'm trying to trouble shoot whether the problem is from the flash button or the cgi script. Has something changed in Flash CS3 from previous versions, where I'm certain it has worked before???
[Code]...
When I have a class linked to a MovieClip in my library and that class takes an argument in its constructor method. That class will compile properly ONLY when it's located in my top-level directory (same dir as the .fla and Document.as files). If I move that class to a deeper directory, say com.place, and update the package statement and symbol link appropriately, the compiler will generate error "1136: Incorrect number of arguments. Expected 0."Create flash project and put a rectangle on the stage. Covert it to symbol and assign it to class TestPanel - or whatever you choose. Also configure the fla so that is uses a Document (Main) class.Create Main.as and TestPanel.as in the same folder. In the Main class, instantiate a instance of TestPanel and add it to the stage. Flash will, predictably, add the rectangle symbol and everything is fine.Now modify TestPanel so that its constructor method takes a Number and have Main.as pass some number to TestPanel.[code]You now get the error: 1136: Incorrect number of arguments.Expected 0.When I move the TestPanel.as into a deeper directory, Flash somehow is looking elsewhere for the base class for Symbol, even though I'm mapping that Symbol to com.place.TestPanel.
View 4 RepliesI've installed a couple of fonts on my Mac that I want to use in Flash CS3, but they're not showing up in the font list.how do I install them so that Flash will pick them up?
View 2 RepliesIs there still really no way to use the Flash Player, whether embedded in a web page or as a projector, to record video files to a local directory on a user's computer?I understand that this is potentially a security nightmare, but I thought Adobe had worked around those issues.
View 2 RepliesloadVariablesNum("script.php", 0, "POST");
That won't work. Could the error be that it's in a movie clip? Or is the script just wrong?
When I was working with a txt file locally I used this command
file = new LoadVars();
fileURL = "PhoneBook.txt";
file.load(fileURL);
[code].....
I have this script for flash player 6.. [kirupa tutorials][code]this is working fine in flash player 6.. but doesn't work in flash player 8.. so the question is how to rewrite loadVariablesNum so it would work?
View 1 RepliesDoes anybody know any reason why I can't use variables loaded from a text file using loadVariablesNum anywhere but in the Var field of a text box? If I try this:
The loadVariablesNum ("textfile.txt",0);it loads the textvariable1=3.14159&variable2=cowfrom the text file, and if I make 2 dynamic text boxes with the Var parameter as variable1 and variable2, they'd have "3.14159" and "cow" show up in them when I run the script. So I know that the textfile is being read and the variables are being loaded.But if I try newvar1=variable1;newvar2=variable2;in my code, and then put newvar1 and newvar2 in my textbbox Var, I get nothing in them. I should be able to assign the newvar variable the same value as variable1, but I can't. trace (variable1);should output the text "3.14159" when run, but it displays "undefined" every time.Every site I have been to says I should be able to access my loaded variable values simply by using variable1, or _root.variable1, or _level0.variable1, but none of these work any differently.
I can assign an instance name to the textbox and then assign a value to that instance name, and if I do that, assuming the instance name is "box")
[Code]...
i'm loading a txt file with loadVariablesNum, which contains : a=1 or, when I try : trace(a) is says : undefined or, when I define a dynamique txt filed and in the properties / var I put the variable a from the txt file : it publishs : 1 so, I can read the variable or I cant use it !
View 5 RepliesloadVariablesNum("script.php", 0, "POST"); That won't work. Could the error be that it's in a movie clip? Or is the script just wrong?
View 6 RepliesI'm trying to make some sort of a GuestBook. I'm using one from flashkit. It's working ok but I need to put the hole thing inside of a movie clip. That's where my problems come out.It's just refusing to load my GuestBook.php.Here's the code for loading variables:
NumLow = 0;
NumHigh = 10;
loadVariablesNum ("GuestBook.php?NumLow="+NumLow+"&NumHigh="+NumHig h+"&R="+random(999),
[code].....
loadVariablesNum("script.php", 0, "POST"); That won't work. Could the error be that it's in a movie clip? Or is the script just wrong?
View 6 RepliesEverything works fine when I'm testing it locally and sending the variables to the live PHP file online, but as soon as I upload it, everything just kinda goes to hell and nothing gets sent through. I know Flash just changed its security settings to not allow loading from external sources, but I wouldn't think that would make a difference since everything (including the PHP file) is under the same domain. I've put the crossdomain.xml file in there, as well, but still to no avail. My code to send things is pretty simple:
ActionScript Code:
loadVariablesNum("mailto.php"+"?name="+name+"&email="+email+"&message="+message+"&to="+to+"&recipient="+recipient, 0, "POST");
I'm making a game and I need to load variables into my flash movie from a database. I'm using asp and I know it works fine because it outputs what I want. My problem is that when I try to load the data into flash, it won't let me use the variables. If I put a dynamic textfield on the stage with fname (one of my variables), the text field displays the correct data, but when I say trace (fname) with having the text field, "undefined" pops up.
View 5 RepliesI'd like to know if there is a way of controlling the variables that are sent with the AS command loadVariablesNum when calling an ASP.Let's say I don't want to send two variables that exist in that frame.
View 2 Replieswhy my MC actionscript with loadVariablesNum("submit.php", 0, "POST"); don't wanna work if I loaded into other _level...
If i don't loaded it work well... but not useful
I've got a question about the path of the txt fileI can easily load a txt file in a movie if the txt is in the same folder as de .swf, but when i try to load a txt file from a different levelfor Example projects/com/1.txt i dīn't see any txtthe code is:loadVariablesNum(projects/com/1.txt,0) i know the code is wrong, but can somebody tell me what i have to do to get a txt form a different level.
View 1 RepliesI have several cutomized checkbox that it can be selected or deselect and I have a button to determine which of the checkboxes is selected, and throught this button I passed the variable to loadVariablesNum corresponding to which of the checkboxes is selected
code in the button to determine which of the checkboxes is selected:
if (chk1.mark1._visible = true){ //trace("31"); loadVariablesNum("http://url?uid="+_root.uid+"&ans=31", 2); if
[code].....
I'm using flashmx and my problem is: i'm loading a txt file with loadVariablesNum, which contains : a=1 or, when I try : trace(a) is says : undefined or, when I define a dynamique txt filed and in the properties / var I put the variable a from the txt file: it publishs : 1 so, I can read the variable or I cant use it
[Code]...
I'd like to know if there is a way of controlling the variables that are sent with the AS command loadVariablesNum when calling an ASP.Let's say I don't want to send two variables that exist in that frame.
View 2 RepliesWhen I test a flash file by hitting "ctrl+Enter" it creates a .swf in same directory as my .fla. does the resulting .swf file actually use the selected publish settings of my .fla file? Or when creating an .swf by "ctrl+enter" does it only use a "default" setting?
View 3 RepliesI have several cutomized checkbox that it can be selected or deselect and I have a button to determine which of the checkboxes is selected, and throught this button I passed the variable to loadVariablesNum corresponding to which of the checkboxes is selected.
[Code]...
I'm importing external vars using loadVariablesNum() from .txt files. I know that each variable must be surrounded by amperstands (&) in order define the start and end of each variable.
ie:
Code:
&var_1=abc&
&var_2=xyz&
And then I want to use something like:
[AS]mc.gotoAndPlay(_level#.var_1);[/AS]
But my question is (for simplicity), is there a way to do this if the amperstand at the end is not included, such as:
ie:
Code:
&var_1=abc
&var_2=xyz
Flash returns the first variable above as var_01="abc " which is understandable since it was not closed properly. However, I want to be able to use the gotoAndPlay(); with var_01="abc ". I have tried labelling the frame with abc , but that didn't work.
I also tried using frame_array = new Array(_level#.var_1.split("")); and then said gotoAndPlay(frame_array[0]); but for some reason I couldn't get this to work either....
I made a simpletext file and used the loadVariablesNum() script in flash to call that file into dynamic text boxes within my flash piece. that's all fine and dandy but now the problem is that I don't know how to make links in that simpletext document to link to specific parts of my flash movie. Basically, I need the simpletext document to have words that you can click that will take you to another frame that has another dynamic box in it with more text.
View 4 Repliesthat can open and save XML data (using the v10 plug-in). The client wants to add a drop down populated with a list of the XML files saved in a Calculations folder. not exactly sure if AS3 can dynamically read the contents of a directory (this would have to work both online and when run as a local app, so server side scripting is not an option). Right now my only idea is to use a manually created XML file that contains a list of the other files in the directory, but this seems quite cumbersome, I rather have the app. just dynamically read wha in the folder.Flash image browsers seem to be able to read all J in folder X, is this kind of thing done strictly through server side scripting?
View 3 RepliesIn Flex How can i get all the filename which contains in a directory in flex AIR.
View 2 RepliesI am trying to load up a xml file from an external source... I search the error code (#2044) and apparently xml can't be loaded unless its in the same directory...
I think this is silly and there must be away around it?
I'm following a tutorial I found on these forums about importing. I'm trying to understand it, but I can't even get the simplest import to work. I get a compiling error: 1084: Syntax error: expecting identifier before as. My form.fla:
[Code]....
is it possible to get the current directory the swf is in? like if I have a movie in a folder called "folder01", i would like to have some code in the movie that returns "folder01".. and if it's in "anotherfolder", it returns "anotherfolder", and so on..
View 7 Replies