Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Writing to a .txt file from Flash... Easiest method? 3

Status
Not open for further replies.

TulsaJeff

Programmer
Jan 29, 2001
870
US
Anyone have an idea as to how hard it would be to write a simple true/false to a .txt file?

What would be the easiest to use... PHP, ASP, PERL? I have not gotten into any ASP yet so it scares me to death at this point but hey... I am a willing student if someone knows some tricks.

I was just thinking that perhaps PHP could do it quite easily. I have a PHP counter that writes to a .txt file...looks like it would work somewhat along the same lines.

any help appreciated. Ya' Gotta Love It!
sleepyangelsBW.jpg
 
davedesign gave me a script that writes to a file using php..the only reason i used php instead of asp is the fact that my server did not support asp due to security reasons..although from my understanding they are pretty much the same as far as scripting goes..so i guess jeff you have to find out if your server supports both then go from there..if you want i'll send you the script dave wrote for me..
logo.gif


carlsatterwhite@orlandomediasolutions.com
 
That would be great Carl...I would love to have a copy of the script.

just send it to tulsajeff@home.com

Thanks! Ya' Gotta Love It!
sleepyangelsBW.jpg
 
sorry Carl... please send to tulsajefff@yahoo.com instead(please note the (3) "F"'s). It seems my @HOME email address is not working.

For anyone who has cox @HOME high speed internet you know what I mean when I say this conversion totally disgusts me. They just sent everyone a conversion package about a week ago saying to reinstall the new software and...by the way... you have to change your email address as well. Less than a week ago and it is not even working but about 5% of the time now... I guess they are trying to phase it out slowly.

I suppose my new email will be something@cox.net or something similar....

A little heartburn....sorry. Ya' Gotta Love It!
sleepyangelsBW.jpg
 
just got in jeff..on the way..
logo.gif


carlsatterwhite@orlandomediasolutions.com
 
I'll stick a few options in an FAQ for future reference over the weekend.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
Virt...I have the file(s) you sent but I am having a little trouble figuring out how to manipulate this thing to do what I want. In the files you sent it basically allows you to write some text and then it bounces the text against what is already in the .txt file... writes the new text to the .txt file and echoes a success message when it is complete as well as loading the new text into the text box.

This is way too much... I simply want to write a simple date to a text file when they sign in to their page. No echo no button to push no nothing. a simple date.

The leader of the group will be able to pull in each users date to see if it matches todays date so he will know if they logged on today...this will in turn give him a pretty decent idea that they have read their "mail" and he can delete/change the information.

All I need is a date written to a text file so I can bounce todays date against the date in the users personal .txt file.

basically an if statement such as ...if [username] = john Doe then write todays date to johndoe.txt

if [username] = Jane Doe then write today's date to janedoe.txt

etc...

then on the leaders page it would have a conditional statement which does something like if johndoe_date=todays date ... logged_in_today=yes

else logged_in_today=no

and would be the same statement for all users.

Am I making any sense at all? Should I leave well enough alone? Be honest...I can take it...

I have already been to the perl forum and they are not offering me much so far...

DavDesign? Virt? Oldnewbie? Anyone done anything remotely similar to this? any tips or words of wisdom? Ya' Gotta Love It!
sleepyangelsBW.jpg
 
hi Jeff

if you send me what Carl sent you I'll sort it to do what you want, unless I find the files on my computer first.

Shouldn't be a problem

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
Dav... I would be forever grateful! I am sending it now. Ya' Gotta Love It!
sleepyangelsBW.jpg
 
ok Jeff:

(for users to login)
(for your manager to check whose in)
(the two flas and the PHP script)

The login.fla contains an array of users in the first frame (dave, bill, sally, frank, killbuz), so that you can't just type anything in to log on.

The date and time is recorded by the fla and sent to the PHP script along with the name of the user logging in. The PHP automatically creates a txt file for that day, whether you've created a text file on your server or not. If one does exist (ie: someone has already logged in) the PHP script will simply append the information to the existing text-file array.

Because everything is concatenated to the text-file to create an array, we can use this in the manage.fla to see who's logged in. The variables are loaded to an mc for checking. The mc takes the array sent from the text file and splits it to make it understandable. This information is then transferred to the dynamic scrolling text-field for the boss to check who's on and who's not.

If this is what your after let me know before I go any further (ie: I'll put a logout function in there too)

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
I think that is exactly what I need! Dav you are the man! How did you do that so fast?

Thanks! Ya' Gotta Love It!
sleepyangelsBW.jpg
 
fast? took an hour to get it all working!

dave ;-)
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
awesome dave..stealing that one for my self..
logo.gif


carlsatterwhite@orlandomediasolutions.com
 
Nice one dave! i'll get one for my self also!;-)
here's star for u!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top