Load Multiple Vars
Hello again my last thread didn't get any answer and I think what I ask is a bit difficult.
Anyway If someone has some good tips I'll be glad too give some good photoshop tips.
How it should look: if I have 60 countries in the database I'll see 60 dots spread on different locations on the screen.
***************
I have an access2000 database with 1 table including the following fields: 1. x-cordinate 2. y-cordinate 3. country
I have an asp page that recieve the data from the database and can create a list of country / x-cordinate / y-cordinate in a table form.
The Problem:
In flash I need to duplicate a MovieClip for each row and the MovieClip's properties will get their values from this row of data.
for example: the first movieclip get the first value: so it's dynamic textbox displays the name of the country.
than the movieclip locate itself in a _x and _y position . the values of this specific _x and _y are the vars from the database.
it must run till the end of the database.
How it shoud look: if I have 60 countries in the database I'll see 60 dots spread on different locations on the screen.
FlashKit > Flash Help > Flash ActionScript
Posted on: 07-04-2003, 03:24 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Load Multiple Vars
Hello again my last thread didn't get any answer
and I think what I ask is a bit difficult.
Anyway If someone has some good tips I'll be glad
too give some good photoshop tips.
How it should look:
if I have 60 countries in the database I'll see 60 dots spread on different locations on the screen.
***************
I have an access2000 database with 1 table
including the following fields: 1. x-cordinate
2. y-cordinate
3. country
I have an asp page that recieve the data from the database
and can create a list of country / x-cordinate / y-cordinate
in a table form.
The Problem:
In flash I need to duplicate a MovieClip for each row
and the MovieClip's properties will get their values from
this row of data.
for example:
the first movieclip get the first value: so it's dynamic textbox
displays the name of the country.
than the movieclip locate itself in a _x and _y position .
the values of this specific _x and _y are the vars from the database.
it must run till the end of the database.
How it shoud look:
if I have 60 countries in the database I'll see 60 dots spread on different locations on the screen.
Multiple Dynamic Text Boxes (load Vars)
-Using Flash 5-
I'm having trouble loading external text into two different dynamic text boxes. I'm sure it's a stupid mistake, but I can't figure it out. I have even tried puting the same exact code in each fram and external file, yet only one of the boxes actually loads the text into it. What I'm trying to do is make a website in Flash and each link goes to a different frame in the movie. In each frame (where the link is directed) there is a dynamic text field where I wish to load text into, however only one works out of all of them.
I have actions (for loading the text) in three different keyframes and one at the end with the dynamic text box (for each 'page')
First frame:
loadVariablesNum ("newsText.html", 0);
Second:
if (done == "okay") {
gotoAndStop(5);
}
Third:
gotoAndPlay(3);
Fourth:
stop ();
That works fine, but only for one text box. I've tried using the same code, changing the level, and changing the variable names -- if (done == "okay") ...--
Can anyone help me out? I'm not sure if all of those actions are necessary, since the external files are small as it is. Thanks in advance.
Dynamic Portfolio (Load TXT Multiple Vars And JPG Flies)
I'm trying to make a dynamic portfolio (loading external JPG and TXT files). The txt contains multiple variables, here is my problem:
I cant make ir work if I load this movie on to a main movie (base). Could you helpme?
Download files and:
Running "main.swf" (don't work)
but if you run "popup01a.swf" It works!
I put the source fla's in
http://www.aztecastupro.com.ar/temp/v/source.zip
thanks
Dynamic Portfolio (Load TXT Multiple Vars And JPG Flies)
I'm trying to make a dynamic portfolio (loading external JPG and TXT files). The txt contains multiple variables, here is my problem:
I cant make ir work if I load this movie on to a main movie (base). Could you helpme?
Download files and:
Running "main.swf" (don't work)
but if you run "popup01a.swf" It works!
I put the source fla's in
http://www.aztecastupro.com.ar/temp/v/source.zip
thanks
How To Load Multiple Html Vars Fron Txt File?
I seem to have come across every way to load vars into flash from external sources EXCEPT using multiple html-formatted vars from a single .txt file, such as:
cha_corp=<html>
<body>
<strong><font color="#CCCCCC">Greystar Corporate Headquarters</font></strong><br>
<font color="#00CCFF">11 State Street<br>Charleston, SC 29401<br>Phone: (843) 579-9400<br>Fax: (843) 579-9420<br>Email:</font> <a href="mailto:bmaddux@greystar.com?subject=website%20contact"><font color="#CCCCCC">bmaddux@greystar.com</font></a><br>
</body>
</html>
chs_corp=<html>
<body>
<strong><font color="#CCCCCC">Greystar Corporate Headquarters</font></strong><br>
<font color="#00CCFF">11 State Street<br>Charleston, SC 29401<br>Phone: (843) 579-9400<br>Fax: (843) 579-9420<br>Email:</font> <a href="mailto:bmaddux@greystar.com?subject=website%20contact"><font color="#CCCCCC">bmaddux@greystar.com</font></a><br>
</body>
</html>
etc...
I realize an ampersand will probably need to be included to make this work. Still not sure of the exact syntax required or IF it will even work this way.
thanks...ba
Best Way To Load Multiple Vars From Urlstring Formated Text File.
OK, I guess this classified as a Newbies question.
I just ever got time to learn it.
But what is the best way to load up multiple url-string formated variables.
I've used the loadVariablesNum("", 0); function but for some reason I cant get this to load a variable from the web (any http://) it works great on the local host.
thanks.
POLL: Best AS3 Send Vars And Load Vars Method
Hi Guys,
Can you help me decide which way to go with as3 to php and back again.
I generally use sqlite, xml or mysql for a database. I don't know if that matters. And sometimes (rarely) I don't use a database at all.
In the past (with as2) I always went custom. Im not sure If id be better off doing something else.
If you have another suggestion please let me know.
Load Vars Doesn't Want To Load It's Vars
I'm trying to initiate a sendAndLoad operation from a remote movie clip. When the visitor clicks the clip, it triggers a LoadVars object in a different movie clip, and asks it to sendAndLoad. This is the code on the trigger clip:
this.onRelease = function (){
_root.albumHolder.albumLoader.albumName = "album1";
_root.albumHolder.albumLoader.sendAndLoad("readAlbum.php",...);
}
where "albumLoader" is the LoadVars object (already created inside a movie clip called "albumHolder"), and "albumName" is it's only variable.
The LoadVars object is created when the movie loads:
albumLoader = new LoadVars();
albumLoader.albumName = "";
____
What I have done so far:
1. I've used a trace(albumLoader.toString()) to verify that albumLoader indeed has a variable called albumName, and that it's value is "album1";
2. I've used a text box to display that trace value. That was interesting. The output was something like: "%5BType%30Method%5&albumName=album1"
3. I've accounted for all possible variable problems by simply calling the sendAndLoad from the button, and fixing the intial value of albumName to "album1"
4. I've used loadVariables("readAlbum.php?albumName=album1,....); This works, so I know that the paths are right, MySQL daemon is working, etc.
It seems that sendAndLoad either will not send the albumName variable, or it is sending a value that is unrecognizeable.
I HAVENT tried the sendAndLoad operation from the clip where albumLoader resides, but this kind of defeats my purpose as I would like to have different clips in the movie talk to this object at different times. As well, there is another LoadVars object doing a load operation, and it's working fine - I'm pretty sure I'm doing something right.
Thanks for any help - my apologies if the answer is a no-brainer... I'm flying by the seat of my pants with this stuff. Loving it, but feeling like I'm riding Wonder Woman's invisible jet plane - the ground is just WAY to visible, and WAY too far away....
Using Load Vars To Load A Dynamic URl Form .txt File AS2
OK I have looked all over the net and these forms for a solution and cant seem to figure out what is going on here. I have a flash header that has a button on it that will change form time to time and I need to pull a url from a txt doc. So here's my code.
PHP Code:
var urlLink = new LoadVars();
urlLink.load("feature_link.txt");
link_btn.onRelease = function() {
getURL("http://"+urlLink ,"_self")
};
In the text file I have
PHP Code:
url=mydomain
When I hit the button I get a web page saying that it cant find the url http://www.url=mydomain.com
I have also tried
PHP Code:
link_btn.onRelease = function() {
getURL("http://"+url ,"_self")
};
and I get http://www.undefined.com/
Why wont it see the url variable in the txt file.
Thax
Multiple Volume Vars
Hi, I was wondering if its possible to have a volume variable for multiple sound objects.. for example is sound 1 and sound 2 are playing at the same time, can i lower the volume for each independently? or does flash allow only one main volume??
I hope this makes sense. Thanx in advance for any help.
Multiple Numbered Vars From TXT File.
Hi,
I'm using Flash MX and PHP o build a guestmap type thing.
I want to save each entries data with an added number in the name.ie the number of entry...
eg.
the 12th entry's data is written to a TXT file like this:-
$currentMaxEntry=12
$input=Name12=$Name<br>Email12=$Email etc etc
The TXT file would lk something like this:-
&Name12=User's name
&Email12=User's Email
So, I was then hoping to tell flash to load the variables by making txt fields to load the variables Name, Email etc by telling it
this.loadVariables("guestmap.txt");
Name=Name+currentMaxEntry (ie Name12)
Email=Email+currentMaxEntry (ie Email12)
But...
this is not working.
Can anyone please tell me what I'm doing wrong. I get the feeling that "+" is not the right way to go about this, or maybe I cannot do this at all....
Any ideas?
Intravenus
Multiple Vars Passed In Timed Sequence?
I would like to pass multiple vars from a database and display them in a timed sequence. The database will be updated three times a day. I currently have the vars in a cfm file that queries the database. As of right now, it only passes the last var. Any suggestion?
Thanks for your input!
AMFPHP Remoting / Retrieving Multiple Vars
Hi
I've just got AMFPHP setup all working ... now I am trying to work out
how to retrieve multiple sets of data .. for example
function handleResult(re:ResultEvent)
{
var myName = re.result;
//set textfield to display variable
myStage.mainText.text = myName;
}
I got this far and I can display single variable ...
What do I need to do to retrieve from DB for example
"heading", "mainText", "Banner" etc ... so I need to populate the site
and I need to put all these in local variables in flash (or assign to textfield like I did in the above code)...
thanks
Passing Multiple Vars From Flash To Javascript
I am having a bit of trouble getting more then one variable to be passed to javascript via actionscript. Here is what I have.
Code:
on(release){
getURL ("javascript:changer(1,2)");//sends the message
play();//plays the next frame of the flash
_global.wheretogo=41;//where to go when certain frame is reached
}
The java script
Code:
/* pretty straight forward */
function changer(yy,xx){
alert(yy);
alert(xx);
}
Some times the browser works and alerts both of them other times it only alerts one. I am not sure how to delay this or if needs to be delayed. Any thoughts would be useful thanks in advance.
Loading Multiple Vars Into Txt Field Problem
I have a movie with six dynamic txt fields that needs to be populated with txt from external txt file. This is the code:
Code:
stop();
//Create the LoadVars object and load data into it
myData = new LoadVars()
myData.load("anastasio2.txt")
//Make a reference to current timeline
myData.ref = this
//Callback handler and data fetching
myData.onLoad = function(succes){
if(succes){
for(var i=0; i<this.cant; i++){
this.ref["Title_txt"+i].htmlText = "<b>"+this["Title"+i]+"</b>"
this.ref["Comments_txt"+i].text = this["Comments"+i]
this.ref["holder_mc"+i].loadMovie(this["Image"+i])
}
} else trace("Error loading data")
}
Have given instance names Comments_txt0, Title_txt0 - Title_txt4 and loader is present.
This is the content of the txt file:
Title0=Problem&Title1=Scary?Title2=Very Scary.Title2= Weird&Comments0=You have had an accident whilst on holiday.&Title4=more etxt to go here
Kept txt in same folder as swf, but when played no txt is loaded. What am I doing wrong? Appreciate help
Yossi
Load Vars Into MC
I'm having trouble getting vars to load into an mc. If I keep them on the main timeline, everything is great, but if I load them in an mc then they don't work. Any ideas?
I Need Load Vars Help...please
I am building a Flash MX site where a section of the site will have Bios of people.
I have a database built out using MySQL and PHP.
I created this button function in my Flash movie
randall.onRelease = function() {
getBio = new LoadVars();
getBio.memberName = this._name;
getBio.send("php/bios.php", "_blank", "POST");
};
This works perfectly! My PHP echoes the info exactly how I need it. URL encoded and all!
randallBio=Randy+was+born+and+raised+in... etc
Now that I know the info is being interpreted correctly, I need to get it back into Flash.
Can anyone help me with converting my current send function into sendAndLoad?
Thanks in advance!
- Patrick
Load Vars
Hello all,
I want to send variables sitting in one swf in an html page to another, different swf in the HTML same page.
Both SWF's sit in the root directory with the page they're embedded in.
Would i use Load Vars for this?
I can't seem to get the 2 swf's to share their precious variables...they just keep repeating, "my precious, my precious" to them! <just kidding).
Thanks.
Load Vars?
I have a web site set up with all the variables in place that i want to load, I used a button to test and it worked and I loaded the variables. But why when I used the same type method on a frame in a MC and in the main timeline it diddn't load them.?
Can I Load Vars Like This?
in movie on frame 1 i have list of vars like so...
text1 = "dga adg adg adgadg adg";
num2 = "gadgad adgadg";
thing = "dgagadgadgd";
etc
can i write these in a txt file (for easy edit)and load em into flash so works as above?
if so how
spam
Want To Load 2 Vars To My Swf
Hi,
i want to load multiple vars to my swf with a while loop in php. I got a tbl_knop (table, mysql) where are located 7 buttons. With the following names: id, knop, link.
while($i < $total ){
$i = $i + 1;
$row = mysql_fetch_array($result);
$knop = $row['knop'];
$link = $row['link'];
echo '
<td><object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="100" height="20"><param name="movie" value="button.swf?knop=' . $knop . '&link=' . $link . '">
width="100" height="20" loop="false" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" link="$link" knop="$knop"></embed></object></td>
';
};
but on this way it will only load the var $knop and not $link. But i need $link to continue vrowsing and navigating within my site.
Who can help me.
grtz ruud
Load Vars
hello all,
when using loadvariables to get variables written in a text file : how do you lay out your text file.
Eg : do you have to declare anything, seperate variables with commas, end it with a semi colon?
any advice would be wicked
thanks
duncan
Load Vars
Hi all,
Just have some queries on the load vars .. it works quite fine ..but still have some very small issues.
When i check for .onLoad(success) in my loadvars script, it means that the Vars has been completely loaded successfully right ?
But when start accessing my vars in a loop using ("split"), the vars remain UNDEFINED when the loop runs first time and when the loop runs the second time and after ..there is no problem ...
I cant understand why it doesnt hold any value on the very first time, even if i load them after checking that all the vars has been loaded successfully.
Is it because it has to search for the vars in the output ?which in turn eats time ....?,Kindly anyone ... explain why dose this happen.
Thanks
Load Vars
Hey everyone,
I have never used loadvars before, today is the very first time i used it... i figured out how to read from a .txt file... sort of... All i did was put var=poop in the text file... Then put
Code:
loadVariablesNum("something.txt", 0, "GET");
in the first frame.. then a few frames later stopped the animation and made a text feild show the variable.. and it worked!... so then i tryed it on an angelfire account.... and it worked!
Now i am trying to make it send information to write onto the .txt file... but i am having trouble figuring out how to...
Does anyone know how to write onto a .txt file, or any other file to store info that can be read... And if so, would you know if it would work on angelfire??? thenks for any help... Peace!
Load Vars
ok, I have this code in the first frame of an animation..
Code:
loadVariablesNum("brickadmin.txt", 0);
And in the text file i have
one=bill
two=matt
... and when it gets them the variable is this
Variable _level0.one = "bill
two=matt"
... I'm not sure how i can load two different variables from a .txt file, i have done it with one in the text file but not two... can anyone tell me what to do... thanks to all!
Peace
~Bill
Load Vars
This is the php code although its been altered here and there.
$query="SELECT * FROM managers";
$result=mysql_query($query);
$num=mysql_numrows($result);
mysql_close();
echo "<b><center><h1>List of managers</h1></center></b><br><br>";
$i=0;
while ($i < $num) {
$agegroup=mysql_result($result,$i,"agegroup");
$namess=mysql_result($result,$i,"name");
$phone=mysql_result($result,$i,"phone");
$mobile=mysql_result($result,$i,"mobile");
$email=mysql_result($result,$i,"email");
//$email= "testing123";
//echo"$email=&email";
echo "<center><font color = blue><b><strong>Age group</strong><br>$agegroup<font color = black><br> Name: $name<br> Phone: $phone<br> Mobile: $mobile<br> E-mail: $email<br><br>";
++$i;
echo "&email=$email";
echo "&agegroup=$agegroup";
echo "&namess=$namess";
}
?>
Please Help With Load Vars....
Hi there,
I was just wondering if someone can help with something.
I currently use this code :
Code:
/* First create a new instance of the LoadVars object */
myVars = new LoadVars();
// Call the load method to load my php page
myVars.load("http://www.myServer.com/loadVars.php");
// Once vars have been loaded, we will have these variables:
myVars.onLoad = function (success) {
if (success) {
trace (" variables loaded ");
for( i in this ) {
set(_root.i, this[i]);
}
} else {
trace (" Error loading variables ");
}
}
to load in variables. This all works fine and all the variables come back fine.
I was just wondering about the myVars.onLoad bit though. In it there is an if - else statement clause. I have never had a problem with variables not loading but was just wondering what would happen if they didn't?
I ran a couple of tests by doing things like making the php file not return any details and other such things so that the clause would hopefully give the error message but no matter what I do it will not return an error message!
I would really love to be able to get the error message to work as I am now creating a site whereby it is imperative that I know whether or not the variables have loaded successfully or not. I thought that maybe the onLoad part of the load vars object would have some sort of a timeout set to it but it doesn't seem to be this way!!
If anyone can help with this then I would be extremely greatful.
Regards,
Mark Bowen
Load Vars And .NET
I am using a LoadVars object to be send to a .Net application.
I pass in a bunch of variable which the .Net application then uses to update the SQL server database.
The database gets updates fine but I am having trouble passing anything a result back to flash.
Here is the flash code. The onlaod fucntion is being called and I am getting success as true but I am not sure as to what to use in the .Net application I tried returning this
Return "strResult=Ok" but that did not work
receivingConsumer_lv.onLoad = function(success){
Debug_txt.text = "Received " + receivingConsumer.strResult + " " + success;
}
sendConsumer_lv.sendAndLoad(XMLLocation_str, receivingConsumer_lv);
Load Vars
is it possible to have multiple load vars in a script...?
Help With Load Vars
Hi... I was wondering if someone could help me here, please....
ok... I made a game, that has records... but when I try to communicate with a php file... well, actually... the swf calls it... but nothing happens... here is the code...
Code:
otroVars = new LoadVars();
ikeVars = new LoadVars();
ikeVars.cat = currentCate;
ikeVars.clicks = clickNow;
otroVars.onLoad = function() {
_root.onEnterFrame = function() {
if (otroVars.loaded) {
_root.onEnterFrame = fade(ok);
} else {
LThabla.text = "ERROR";
_root.onEnterFrame = null;
_root.onMouseDown = function() {
_root.onMouseDown = null;
_root.onEnterFrame = fade(bad);
};
}
};
};
ikeVars.sendAndLoad("monotono.php", otroVars, "GET");
Now... the thing is... if I put the comlete URL (http://www.mypage.com/monotono.php) this thing works perfectly.... but if I put it like in the code above ("monotono.php")... nothing happens... the "ERROR" text never appears... what's going on?... please someone....
I have Flash Mx 2004... and I export my movie in Flash 7 version....
Load Vars To Php
Hi,
I looked for this on this forum; however, the posts I found are not really what I wanted.
Basically, I want to send a variable from Flash to a php file when user clicks a link (movieClip). After the variable is sent, I want to refresh the whole php page.
This the code I currently have for sending the variable from Flash:
Code:
minesweeperSC.onRelease = function(){
minesweeperloginVar = "minesweeperLogin";
}
myVars.sendAndLoad("index.php",0,"POST");
This is the code on my php file:
PHP Code:
<?php
//receive var from flash
$page = $_GET['minesweeperloginVar'];
echo"This is page value:" . $page;
?>
Any help will be very much appreciated, an example will be perfect.
E
Load Vars
trying to follow a very simple tutorial, but cant make it work
PHP Code:
this.createTextField("msg1_txt", 1, 200, 200, 100, 20);
hintLoad = new LoadVars();
hintLoad.onLoad = function() {
msg1_txt.text = hints;
};
hintLoad.load("hints.txt");
where the text file, hints.txt reads
Code:
hints = hint
but the result is simply
Code:
undefined
Load Vars Help
Hello all you Action Script Boffins
I need you to help me on a LoadVars Problem
Please imagine two Library Symbols that are not on the Stage but in the Library
With both of there Linkages Set to Export with the Movie.
One is called "box" and the other is called "circle".
What I want is to create a LoadVars Function that imports a .txt file called
"objects.txt", which holds the following x and y co-ordinates of
the two Symbols
"box" 200,250
"circle" 100,150
1.What would the ActionScript need to be like keeping it Simple and Minimal
With no Trace Functions or Confusing Names and the Script needs to be fully complete
As I have had replies that only give part of what I need and don’t work. No timewasters.
2.What would the "objects.txt" file be like including all the correct punctuation's.
Can Anyone Help Please
Alan
[MX] Load Vars From Url
Hello im trying to make a hostable hit counter its easy to do in php im not sure how to do it in flashmx example hitcounter.swf?id=test
and in the flash example I want to load text file test thanks.
Load Vars
I am trying to execute this script
ActionScript Code:
stop();
var LV:LoadVars = new LoadVars();
var myUrl:String = "http://blogonize.com/vars.php?user="+_root.u;
LV.load(myUrl);
LV.onLoad = function() {
#include "playlist.as"
};
onEnterFrame = function () {
if (LV.total == currentLevel.recordedSongs && LV.total != undefined && currentLevel.recordedSongs != undefined) {
delete this.onEnterFrame;
currentLevel.totalSongs = LV.total;
gotoAndStop(3);
}
};
if i define _root.us in the begineing like so
ActionScript Code:
var LV:LoadVars = new LoadVars();
_root.u="Bob";
It works fine.
But if i make this into the embed code
HTML Code:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="389" height="294">
<param name="movie" value="podcast.swf?a=true&u=Bob&v=70">
<param name="quality" value="high">
<embed src="podcast.swf?a=true&u=Bob&v=70" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="389" height="294"></embed>
</object>
However if i print myUrl into a dynamic text box it traces http://blogonize.com/vars.php?user=Bob
wich is what it is soposed to be. But it does not load the url...
Any ideas?
Thanks for your time
~Gabor
IE Cannot Load Vars
Hello (again)
Suddenly I have to build a small and o-so-simple Flash Movie. What have I started...
This is the code (and it works just fine) BUT NOT IN IE:
-----------------------
function showContent() {
//handling loadvars
_root.args = "";
for (i in this){
_root.args += i + " = " + this[i] + "<br>";
}
}
stuur = new LoadVars();
stuur.ALIAS = _root.nm;
ontvang = new LoadVars();
ontvang.onLoad = showContent;
stuur.sendAndLoad("script.php", ontvang, "POST");
------------------
The PHP-script simply sais:
echo ("&var1=bladibla&var2=grrr");
or
printf ("&var1=bladibla&var2=grrr");
------------------
As I said it works just fine in Mozilla en FireFox, but IE does not seem to get any variables back from the php-script - the sending goes fine. This may be caused bij the php-session, but that session is inevitable in the scripts.
So, how do I make sure that also IE receives the variables
Thanks en ragards,
Victor
IE Cannot Load Vars
Hello (again)
Suddenly I have to build a small and o-so-simple Flash Movie. What have I started...
This is the code (and it works just fine) BUT NOT IN IE:
-----------------------
function showContent() {
//handling loadvars
_root.args = "";
for (i in this){
_root.args += i + " = " + this[i] + "<br>";
}
}
stuur = new LoadVars();
stuur.ALIAS = _root.nm;
ontvang = new LoadVars();
ontvang.onLoad = showContent;
stuur.sendAndLoad("script.php", ontvang, "POST");
------------------
The PHP-script simply sais:
echo ("&var1=bladibla&var2=grrr");
or
printf ("&var1=bladibla&var2=grrr");
------------------
As I said it works just fine in Mozilla en FireFox, but IE does not seem to get any variables back from the php-script - the sending goes fine. This may be caused bij the php-session, but that session is inevitable in the scripts.
So, how do I make sure that also IE receives the variables
Thanks en ragards,
Victor
Load Vars From GET
Hi everyone!
The URL of the page where my movie is loaded is like:
http://www.mysite.com/index.php?s=about
How can I do to receive the value of "s" (about) in my Flash movie and manage that value in my code?
I want to do in my code something like:
if(s=="about"){
gotoandPlay("something");
}
Any solution?
Thankz!
Load Vars From Php Or Txt Urgent Help
ok i kind of want a news thing on my movie. I want an external file to contain, a title, a link and the actual news. On the main page i want the title displayed that loads a frame with the news and title when u click on it. Anyone no how i can do this
Load Vars Calrification.
When using LoadVars, does the file that you are calling from Flash...say "file.php" need to be on the same domain as your Flash file or can it live on a different domain?
I though it had to be on the same domain...
Thanks
Load Vars From A Txt File
I know that there is a pretty easy way to do this but i can remember how. I am trying to load a list of usernames and passwords from a txt file on a webserver. I just cant figure out how i was able to load them in previous flash logins ive made. If somebody could just point me in the right direction it would be greatly appreciated. Thanx,
Brandon
Load Vars Issue
I've run into a small problem while trying to load information from a php file. For some reason, it's not showing. Here's what I've got:
Code:
// My text file has one line which is:
// &display=blah blah blah whatever I want to display
// Here's my AS:
function dispShow(){
recent.text = show.display;
}
function getShow(){
recent.text = "Loading Media";
n = Math.random();
show = new LoadVars();
show.onLoad = dispShow();
show.load("scripts/nextShow.php?n="+n);
}
getShow();
stop();
Alls I get is a blank text box. Any takers? Thanks.
Load Vars Repetition
I need to read a repetative set of variables into a swf creating a new record for each RECORD=NEXT flash seems to be deleting the previous identically named parameters though so instead of having a complete record displayed on screen only the last set of variables are visible both on screen and when I put trace on them.
the counter shows however that there were a number of instances of
RECORD=NEXT
//Code below is stripped down
AccBal = new LoadVars()
// eg :AccBal_rp = a=a&b=B&RECORD=NEXT&a=A&b=B&RECORD=NEXT etc,etc
AccBal_rp = new LoadVars()
if (AccBal_rp.loaded) {
with (AccBal_rp.RECORD) {
i_array.push(AccBal_rp.RECORD);
I++;
trace("***********^^I******^"+I);
trace("***********^^i_array ******^"+i_array[i]);
trace("***********^^I******^"+AccBal_rp.RECORD);
}
AccBal.sendAndLoad("*********",AccBal_rp ,"POST")
any ideas? I have tried to load the variables into an array but it doesnt seem to work.
Thanks in advance
Rob
Load Vars Repetition
I need to read a repetative set of variables into a swf creating a new record for each RECORD=NEXT flash seems to be deleting the previous identically named parameters though so instead of having a complete record displayed on screen only the last set of variables are visible both on screen and when I put trace on them.
the counter shows however that there were a number of instances of
RECORD=NEXT
//Code below is stripped down
AccBal = new LoadVars()
// eg :AccBal_rp = a=a&b=B&RECORD=NEXT&a=A&b=B&RECORD=NEXT etc,etc
AccBal_rp = new LoadVars()
if (AccBal_rp.loaded) {
with (AccBal_rp.RECORD) {
i_array.push(AccBal_rp.RECORD);
I++;
trace("***********^^I******^"+I);
trace("***********^^i_array ******^"+i_array[i]);
trace("***********^^I******^"+AccBal_rp.RECORD);
}
AccBal.sendAndLoad("*********",AccBal_rp ,"POST")
any ideas? I have tried to load the variables into an array but it doesnt seem to work.
Thanks in advance
Rob
Objects With Load Vars
yea, confusingness... I am trying to import string values from a text file and then put them into an object like this...
Code:
loadVariablesNum("brickadmin.txt", 0);
_root.names=new Object();
_root.names.one=_level0.one;
_root.names.two=_level0.two;
loadVariablesNum("brickpass.txt", 0);
_root.npass=new Object();
_root.npass.one=_level0.pone;
_root.npass.two=_level0.ptwo;
The values brought in from the text file are there, as one, two, pone, and ptwo... but it wont take them and store the value into the objects... Any suggestions on what to do.
Thanks,
~Bill
Load XML Into Class Vars
I am trying to dynamically populate some class values with an XML file. However when I attempt to do this I don't get expected results. My setup is like this
Code:
class someClass
{
// Attributes
private var myVars:Array;
function someClass(file:String)
{
loadXMLFile(file);
}
public function loadXMLFile(file)
{
//Open XML file
var xmldoc:XML = new XML();
xmldoc.ignoreWhite = true;
xmldoc.load(file);
xmldoc.onLoad = function(success)
{
//If successful load values in data set
if(success)
{
if(xmldoc.firstChild.nodeName == "myNode")
{
var myNode = xmldoc.firstChild.nodeName.childNodes;
for(var i = 0; i < myNode.length; i++)
{
myVars.push(myNode[i].firstChild);
}
}
}
}
}
}
When I trace the XML I can see all of my values, but I believe what is happening is that the XML.onLoad function is running inside of the XML class and not inside of my class. I do have a work around where I don't include the loadXML function inside of the class, but it would be nice to keep it here since it would make it easier for the users of my class not to have to write the xml code. Any help is welcomed and appreciated!
Load Vars From A Php File
Hi all
I'm wanting to load a variable from a php file and I've found heaps of code on this but I can't seem to work it out to do what I need.
I think it's the "LoadVars();" actionscript I need to understand.
hear is the variable in the php file:
PHP Code:
<?php
$head = $_GET['head'];
?>
The head is set from an html link.
and it's hear where I need to get the $head variable into flash and then do the following:
if $head = 1 then gotoAndStop("lable_1");
if $head = 2 then gotoAndStop("lable_2");
if $head = 3 then gotoAndStop("lable_3");
And so on and so on......
Any ideas
Cheers
Chris
Load Vars Problem
Hi, need some help. If anyone can help it would be really appreciated. Here's what I got...
I'm running MX 2004, I have a main movie, when a certain button is selected it loads a new swf inside the main one, helps keep overall file size down. The problem is that the loaded swf has a load vars command in it, once the movie is loaded into the new one the load vars doesn't work. I have a feeling is has to do with the _root command but I have no idea how to fix this. Here's my load Vars actionscript, any thoughts??
code: var myLV = new LoadVars();
function loadNews() {
myLV.load("news.asp");
myLV.onLoad = function(success) {
if (success) {
_root.strNews = this.strNews;
} else {
// try again, nothing loaded.
}
};
}
loadNews();
Thanks in advance.
|