Loading Text File Without Cache?
I have a flash file that open and saves a text file using php. its used as a database, it works well and all.. but since its running through the internet... when it loads and open the text file, i guess it saves it in the browser cache, so when i do any changes it saves it correctly, but when a reload it loads the file in the cache not the one on the net. I have to empty the cache and then it works fine. Dont know if there is a way around this, if there is please let me know
thanks
FlashKit > Flash Help > Flash ActionScript
Posted on: 03-17-2004, 01:30 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Loading Txt File - Kill The Cache
I am trying to create a live-feed 'Ticker' style movie that loads a set of variables from an remote text file, and displays them in the movie. There is an internal timer which, after say 1 minute, reloads the same text file (so in theory, if the text file was updated it will overwrite the original variables and display 'new' data).
I have got the function working (reads the text file and shows the results), but I am having a problem with caching in the browser. Unless I clear my cache, the 'updated' text file, although theoretically loaded, is not displayed and the older data remains visible.
Any ideas, or alternatives?
I have tried using the 'loadMovie' function (the loaded movie contains the variable call/t & text fields) and then, using the same timer function, 'unloadMovie' after 1 minute and simply repeat the whole process to create the loop/live feed. But when I tried this, I cant get the loaded movie to display at all using With/Tell target, and get errors saying 'target not found' etc. Only when I use the 'loadMovieNum Level, 0(or) 1 (or) 100' thingy does it work, problem here is that I cannot hide/position the loadedMovie within a specified (masked) area of a GUI, as the text/imported movie is always on top of the 'Parent', i.e. foremost.
I'm chasing my tail here, and I may well be doing something rather obviously wrong, but when you can't see the wood for the trees...
Rob.
Why Does It Cache My Text File?
I have a big problem. On a Flash site that I am doing, I load a text file that has descriptions for a bunch of buttons. These descriptions will change very often and show up on button mouseover. My problem is the txt file is being cached and isn't updating when it is changed on the server. Is there anyway to make it re-download the text file if it is newer than the cahed one? It can be seen at http://www.snideworld.com/snidog/eric . It is the Nav Bar.
Why Does It Cache My Text File?
I have a big problem. On a Flash site that I am doing, I load a text file that has descriptions for a bunch of buttons. These descriptions will change very often and show up on button mouseover. My problem is the txt file is being cached and isn't updating when it is changed on the server. Is there anyway to make it re-download the text file if it is newer than the cahed one? It can be seen at http://www.snideworld.com/snidog/eric . It is the Nav Bar.
How To Un-cache A External Text File
Hi all,
I'm loading a HTML formated text file into the root level and it works exactly how I want it. The problem is when I update the file it does not reflect the changes when the movie loads again. I am thinking this is a caching problem in IE 6. I have not tested in NS for to many reasons to list.
If anyone knows how to fix this please help!!!!
It is driving me nuts.
TIA
Wes/
Text File Or Cache Handling In Flash
Hi!
I would like to show a text file in Flash. I read this file with LoadVariablesNum command and it works but if I refresh the text file on the server it doesn't change in my flash because the text file is read from browser's cache.
How can I reach the text file always from the server or how can I turn off the cache for this file in Flash ?
(my users perhaps won't change their browser settings)
Thanks in advance,
Jules
Write To Text File (reading From Cache)
Hi,
I need to write a flash poll ystem. I am using a php script to read and write to a single text file. But flash gets the data from cache so i cannot see the updated entry.How can I get rid of this situation? Could anybody help me?
Dynamic Text From Txt File/Eliminating Cache
Hey all,
I have a flashmx movie that uses a dynamic textbox to display the contents of a .txt file. I'm using a flash component called LoadText version 1.2.2.
Everything works fine with one exception. When the contents of the .txt file changes, those changes are NOT reflected in the flash movie.
I think the problem lies with the browser caching of the flash movie. Anyone have any solutions?
Thanks!
-DB
Loading Dynamic Text And Cache
Hi all
I have text load dynamically into a text file on my site but because of caching if I update the text file I don't see the changes unless I delete all my temp internet files from my system, Is there a way to get around this so that it'll be updated as soon as I change the text file and return to the site and not only when i delete my history files?
Any help is greatly appreciated thanks
Roark
Dynamic Text Cache In Windows Projector File
I've been searching for an answer, but have not found one that addresses this exact issue. I designed some informational kiosks. Most of the text is dynamic text that is updated multiple times each day. The kiosks are simply running Flash Windows Projector exe.
The problem is that when I update the text files that get pulled into Flash, they never get updated in Flash unless I restart the projector file. The kiosk is a Flash slide presentation (12 screens). On the first frame of a screen, I have this as my code to load external text into my dynamic text field.
_________________________________________
var data_loader:LoadVars = new LoadVars();
data_loader.onData = function (src:String):Void {
Quote_txt.text = src;
}
data_loader.load("Quote.txt");
________________________________________
Quote_txt is the dynamic text field
Quote.txt is the external text file that contains the text to display.
How can I force Flash to reload the text each time it is to be displayed?
Thanks for the help. I know this subject has been covered many times before, but the solution always uses some AS that effects the browser. In my case, there is no browser, so those solutions (random variables) do not work.
Vars From Text File, Not Updating Changes, Must Clear Cache, Then Reload Page.
I am having some cache problems.
The code below is for updating a users profile,
When a user makes changes,
he/she is redirected back to the SWF where the editor is,
but the values remain the same.
They might think it did'nt update their changes,
but it did.
I tried using:
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache">
in the html where the swf is embeded,
but it did not work.
Is there some sort of cache control,
or a way to reload the new vars using actionScript.
I'm open to any ideas,
The code is below. Thanks.
Code:
stop();
loadText = new LoadVars();
loadText.load("../members/" + _root.username + "/profile.txt");
loadText.onLoad = function() {
genderSex.text = this.genderSex;
DOB.text = this.DOB;
location.text = this.location;
aboutMe.text = this.aboutMe;
};
function updateSex(){
this.genderSex.text = genderSex_drop.getSelectedItem().label;
}
//
function editProfile(){
username = _root.username;
password = _root.password;
genderSex = this.genderSex.text;
dob = this.DOB.text;
location = this.location.text;
aboutMe = this.aboutMe.text;
//secret = "HIDDEN";
getURL ("../change.cgi", "", "POST");
};
Load Variables From Text Then Loading Image File With The Filename Given In Text File
The problem is, that i need flash to load variable from text file, eg: info.txt, with image=gt.jpg in it.
Then I want flash movie to load a gt.jpg into a blank movie.
The point is that after i change filename in txt file, i want movie to load that img.
I wrote AS:
loadVariablesNum("info.txt", 0);
loadMovieNum(image, 0);
but it's not working
After i traced variable image, debugger showed that this variable undefined, but if i put textbox with image as variable, it shows "gt.jpg".
Please help
Loading An Array Of File Names From A Text File.
Basically I want to do the following.
Create an array of
Image[x] = "x.jpg"
from a text file where the images are listed as
x.jpg
y.jpg
z.jpg
I can't figure out how to load these in an array and I haven't been able to produce this from the closest examples I have found.
Any suggestions?
Dynamic Loading Text File Not Loading Correctly
I am loading info from a text file (noticeBoard.txt) using the following code;
sourceTXT = "noticeBoard/noticeBoard.txt";
nodeSource = new LoadVars();
nodeSource.onload = gotoAndStop(printText);
nodeSource.load(sourceTXT);
Then writing it into a textfield when the timeline moves to the 'printText' frame.
The swf is working when I load my html page (notice.htm), with all my values being displayed. If I then navigate away from this page to one where I write more info to the text file and then return to notice.htm the latest info in the text file does not show in my swf. Even if I refresh the html page the new info does not appear until I shut my browser window then reopen it.
Does anyone have any suggestions to why this info is not coming in on the fly?
Thanks
Loading A Html-tagged Text File Into A Text Field...it's Just Not Working For Me...
hi,
i'm trying to load news.txt into a textfield using loadvars.
news.txt:
-----------------------------------
&news=<p font face="Verdana" size="12"><b>Recent Achievements:</b><br>Congratula etc. etc.
the as:
----------------------------------
loadnews = new LoadVars();
loadnews.load("flash/news.txt");
loadnews.onLoad = function(success) {
newstext = loadnews.news;
trace(newstext);
gotoAndStop(2);
}
the trace is showing that newstext is the text out of news.txt ... in the frame 2 that the onLoad function refers to is a textfield (multiline, with the html as true) which is supposed to display the newstext variable.
If i set newstext to something else ... eg: newstext = "some text" then it works fine ...
what's going on???
Cheers,
Ben
Loading External Text File Into Flash Using Links From Dynamic Text Field Link?
I am using a dynamic text field to load in .txt files with html tags. I have a couple "click here" type links that I would like to use to load a different .txt document into the same dynamic text field instead of a url link like it does default. Is this possible? I'm sure I could put a button over the text since its not long enough to need a scrollbar but I would like a more dynamic and flexible way to do this if its possible.
Thanks
Loading Pictures From A File Like Loading Text..how To Do It?
I don't know if this is possible...but I'll ask it anyway.
I know how to load text into a flash movie from a text file, (the load variables function), but is it possible to load an external picture file, like a jpg or a gif in the same way without using the flash program?
If it's possible, can someone please tell me how it is done?
Thanks,
JRL
http://www.xtranix.com
Txt File Cache
There is probably a post about this among the thousands of postings on this board, but I couldnt find it.
How can I make a text file not be placed in the users cache, so it can always show the updated txt file on my server and not pull the file from their cache?
I did find some code that supossedly does this at
http://www.bokelberg.de/actionscript/25.html
but couldnt get it to work correctly.
so please help..
gracias
dduck1934
.SWF File To Cache
Hi there!!!
I just would like to know that, how can we protect our .swf file being dowload to the visitors cache? I have uploaded all the files to my server as default published files. My web site address is www.wefourgroup.in if you would open my site all the .swf files would be downloaded into you cache, I just want to stop that how can i do that?
Thanks
ALA
No Cache Xml File
i've used this before:
Code:
linkXML.load("links.xml?var="+random(100000));
to ensure the xml file gets loaded afresh each time.
for some reason It won't work now... i get an error that it can't find the file
"links.xml?var=2609"
anybody got any ideas?
Loading External Text File Into Text Area (flashMX)
Hi,
I am trying to load text from an external text file into a textarea in FlashMX. I am able to set the contents of the textarea by using a string ("test thingy"), but I was wondering if anybody could point me in the right direction on hoe to include text from an external file.
Used to set string:
scroller.text="test thingy";
Thanks a bunch,
Niklas Wahlberg
Loading HTML/Text From External Simple Text File…
To all the Flash Gurus:
Basically how do you do the above? I've gotten very small snipets of text to load from an external text file, but there was probably at maximum 50 characters. This is even after a long load time and a very fast connection (T1/off of the HD).
I'm trying to get this to work so that I don't have to update the flash files to update the text - or rather so that someone else can update them w/o me acting as a middle man except for special occasions. The best example, I think, of what I'm trying to do is www.spartamusic.com
Thanks-
Davin
Loading Text From A Database Into A Text File Inside A Movieclip
Okay. I have a movie clip with two frames. Inside frame 1 is a text box named "home_copy". The mc in which this textbox resides is given an instance name of "copy". Frame 2 has a different text box (we'll worry about this after solving probelm 1.)
So I'm using loadVariables so that the site is compatible with old browsers.
The PHP file I'm grabbing has this at the end:
Code:
&home_copy=Welcome to EROS. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. etc.
So how do I get my php source code to go into the text box, "home_copy", which is embedded into a movieclip, named "copy".
thanks
Loading Text Into Mulitple Fields From A Single Text File
Hi there. I am trying, and failing(so no soucre) to make text load dynamically into multiple fields.
I am trying essentially to load text using only one text document- into several fields. This is so I can run a very primitive cms system in flash. (all the fields need to call different portions of the text.
If anyone understands what I mean and how it could be done, it would be great
Loading Text From Text File And Then Scrolling It Using Components?
Helloo.
Can anyone please help me.
I want to dynamicaly load text into flash, probably from a txt file. Then I want to be able to set up my file so the text field is scrolable using the 'scrollbar' component.
Can anyone please help? Everytime I do it my text field wont scroll, even though I'm sure there is more text than can be seen?
Can anyone help with a .fla?
Cheers SHACK.
p.shackleton@brahm.com
Loading A Text File Into A Dynamic Text Field
Ok I have a dyamic text field called "Load"
I have a text file that is a few paragraphs, Is it possible to load the text file into that field?
I was think Load=loadVariableNum("http://www.___.com/text/text.txt","GET");
Maybe something similar. Thanks
Loading External Text Without Variable Name In Text File
i need to be able to load text from a file and put it in a dynamic text box but i cannot modify the text file to put in a variable name
ie the text file cannot contain variablename=1234
but rather must simply contain 1234
Is it possible to load some text without a variable name indicated in the file using flash mx 2004 and, if so, how would one do this?
Loading Actions And Text From External Text File
how do i do this....
i would like to add links to my flash webpage via an external text file. i have 6500 links to admin.
if possable would i be able to tell a button to goto a different url from an external text file.
Loading Values From A Text File Into Dynamic Text Box
Hello,
I'm using the as code to load a text file and trying to set it as the value for texboxes;
Code:
loadVariables("data.txt","");
date_text.text = date1;
title_text.text = title1;
entry_text.text = entry1;
the textfile is;
&title1=Welcome to my Flash Blog
&date1=13th November 2005
&entry1=This is the first entry in my blog. This is sample entry and all the data.
The as code has all the correct names of the dynamic text boxes, also it works fine if i put the names of the varibles from the text file as the var propertie of the tex boxes, but i dont want to use this method.
im sure its a silly little error, but been searching for a solution for over an hour with no luck
Loading Text Into Text Fields From An External File…
I have a file supplied to me with a couple of text boxes in it.
My friends would like to easily update the content of these boxes by using an external text file.
I have tryed tests with the "loadVariables" property, but can't seem to get any text to load at all. I have a text file called "Content.txt" and the dynamic text box has an instance name of text1 (original I know) and a variable name of myText.
The beginning of my text document starts of with "myText = "…
The line of code I was using was
loadVariables("Content.txt", text1);
this produced no result… does anyone have any suggestions for this problem?
Cheers.
Joel
Dynamic Text Issues When Loading From Text File
I've got a dynamic text block that loads text from a text file in the same directory as the flash file. The dynamic text area is scrollable, renders the text as html, and applies the stylesheet that i load externally correctly. For a scroll bar i used the UIScrollbar in Flash MX 2004 V 7.2
If i test out the movie clip on it's own it loads fine and all the text shows up in the text area. However, if I load the movie clip into a time line, where it is animated, in other words, if i have a motion tween on it, all of the text shows up in the area, but the scroll bar won't scroll down far enough to read it all. The only way to see all of the text is to highlight it and drag down.
I've tried calling the scrollPane.refreshPane() action after the motion tween but nothing seems to work to get the scroll bar to go all the way down to the last line of text.
I'm pretty sure this is another bug that has probably been worked out somewhere else, and I just can't find the solution online.
Any ideas?
Thanks,
Nate
Loading Dynamic Text Without External Text File...?
Hello,
I apologize if this has been asked before as i'm sure it has but for the past few days with all my searches on sitepoint, google, and flash kit but haven't been able to accomplish it.
What i'm trying to do is have text in my flash movie change based on a variable displayed on a WEBPAGE. I tried to accomplish this using FLASHVARS but i'm not even sure if I used flashvars correctly since not only did it not work but I couldn't find a tutorial that told me what i had to do inside the .fla file to make the flashvars function work.
I was wondering if someone here can point me into the correct direction or explain to me how exactly i would go about doing this...?
Again, all i'm trying to do is make a text in the .swf file change based on a variable in the web page, such as how FlashVars works...
Thank you in advance, and again i apologize if this was answered before.
Loading Dynamic Text With Hyperlinks From A Text File.
Is it possible to load text from an outside source using loadVarsText.load("text.txt"); and have some text bold and other text have html links?
Where can I find how to do this, or is it even possible?
I'd gladly pay you on Thursday
for a hamburger today!
Loading External Text File Into Dynamic Text Box
I have a dynamic text box on my stage that has a set width and height i want to populate it with an external text file to make it easy to update the text with out having to touch the fla. I'm just beginning to learn AS3 and don't know were to begin, in AS2 i would give the text field a variable and in my text file start with the variable name= ,variable on text isn't supported by AS3. any help would be appreciated.
Jake
Cache And .swf File Issue
**********//////// As usual 10 minutes after posting a question on the forum the I find the answer..........
"loadMovieNum" instead of "loadMovie" seems to work, when using the variable.
Don't no why yet, so any comments appreciated.////////************
I am building an image intensive website, to cut download time I have split the movie, and am using the "loadmovie" function to access the seperate sections of the site.
The problem I am having is that when I upload the movie to the server the .swf files are getting cached, I have a suspicion that that may even be happening on the server. This is preventing me from updating the various sections of the movie.
To prevent the caching I'm trying to place a random variable on in this manner.....
on(release){
rn = Math.round(Math.random()*1000000);
loadMovie("new_movie.swf?="+rn,0); // doesn't work
//loadMovie("new_movie.swf?=3",0); // works (not random though)
}
Am I going about solving this problem the right way? and if so, can anyone tell me where my code is faulty?
T.I.A.
File Cache Usage
Sorry for bad english...
In "Magnum In Motion" application (http://magnuminmotion.com) slideshow, when it started at the first time, rapidly preloads jpeg-pictures. And, if you quickly press on some ot the ending pages - you will see small preloader icon and, after moment, loaded picture.
But if you refresh page, even after closing browser, and load the same slideshow and the same page, so - just repeat all of your actions - you will not see preloader icon...
Is it user-defined cache and action script loaded at the second time locally saved files? But security police don't allowed work with local files, isn't it?
Is it http-server cache usage? In that case - the main question:
Is it using automatically, when script calls loadMovie(), or it's user-defined usage of http-cache ?
Cache Issue :SWF File
Hi Everybody,
I want to refresh my .swf without clearing the cache or files. As we all know that just refresh doesn't work. So after quite a bit of searching i got some code here:
http://www.kirupa.com/developer/acti...icks/cache.htm
But i tried that without any luck. Does that work in all cases. And i am not sure if i am doing it corrrectly. What i did is - i created a New Blank file and on first frame i added this
myIdentifier=Math.round(Math.random()*10000);
loadMovie("myfile.swf?uniq="+myIdentifier,1);
It does embed myfile.swf but refresh still doesn't work. Is there any other method of achieving this thing.
Thanx.
Loading Swf's In The Cache
Can anyone tell me how do i load the swf's used in my website in the cache even before they are called for.
IE Keeps Loading From Cache
I always have problems with IE when developing Flash applications.
Problem
For some reasons, IE just won't reload my swf file even if I
1. updated the swf on the server.
2. cleaned the cache, history, and even cookies
3. reboot my computer
I really have no idea where Ie is loading the old swf from...
Can anyone help mw with this issue?
[Q] Why Not Loading From The Cache?
Not much of a preloader fan, I must say...
Okay... Here is a quickie script that does preloading... It works fine, I think...
But if I reload the page by pressing F5 in IE, the movie starts all over and you can see the preloader text everytime you refresh the screen...
Isn't IE suppose to load it from the cache if it is loaded once???
Here is the URL you can check...
http://cyanblue.flashvacuum.com/tmp/ProgressBar.html
and here is the AS I am using in frame 1...
ActionScript Code:
var _l = this.getBytesLoaded();
var _t = this.getBytesTotal();
var _p = Math.ceil(Math.round(_l / _t * 100));
this.progress_txt.text = _l + " / " + _t + " : " + _p + "%";
if ((_l >= _t) && (_t > 20))
{
trace("LOADED");
this.gotoAndPlay("LOADED");
}
and in frame 10...
ActionScript Code:
this.gotoAndPlay(1);
Any idea???
Loading / Cache
If I use a MovieClipLoader to preload an image, say, a JPG; is that JPG then already cached if I were to view it on a regular HTML page, or does FLash have its own cache which is seperate to the browser's?
Dynamic Text, Loading Text From Text File
I have a large text file, full of, believe it or not, alot of text. When it loads into the textbox in flash, it cuts off after a certain amount of lines. How many lines does it cutt off at and if I can, how do I increase this? THanks
I Want To Delete Swf File In Cache From Browser
Hello,
I want to delete swf file saved in cache during internet download procedure....
I want to delete it through my browser or swf file...so I can make it secure....
waiting for reply
Regards,
Danish
Cache And External Txt File Troubles
I understand this is a common problem but didnt understand how to fix it.
When I use loadVariables("file.txt"); in flash movie from browser it doesnt refresh the text file, it just uses old cached version..
how do i fix this?
How Do I Get A SWF File To Update If It Is Newer Than The Cache One?
How do I get a SWF file to update if it is newer than the cache one?
At the moment EI puts a SWF into the cache and when I upload the new SWF, nother changes. After I delete all the saved files, I can see the new SWF.
Is there a way to get the SWF to update the cache if the file is newer than the old cache data?
Regards,
Glen Charles Rowell
Clearing Swf File From Cache In ASP Situation
Greetings,
I am using a Flash frontend with an Access database. When a user submits a comment, it is forwarded to an asp page and is stored in the database. The asp page then redirects back to the swf, which pulls all of the info back out of the database.
Problem: The swf does not recognize the new post(s), and lists only the records available since the beginning of the session. I have tried Session.Abandon, Meta Content Tags etc. but have no luck. The swf refuses to see any new posts unless the browser is closed and reopened.
Blargh.
Any insight would be appreciated,
Mike
Not Loading From Cache If New Swf Uploaded
Anyone out there know how to make it so my site will load the new swf file if it has changed since the veiwers last visit?
Is it a piece of html code to chuck in, of something to do with the swf file?
any help greatly appreciated.
-luap
|