Page 1 of 1

Editing A .txt file in php?

Posted: Thu Oct 27, 2005 3:41 pm
by word32
i have this .txt(datasheet.txt) document that contains my flash radio info, that my flash program reads

it looks like this:
&tracks=10&
&track1=song1.mp3&
&track2=song2.mp3&
&track3=song3.mp3&
&track3=song4.mp3&
&track3=song5.mp3&
&track3=song6.mp3&
&track3=song7.mp3&
&track3=song8.mp3&
&track3=song9.mp3&
&track3=song10.mp3&

i want to be able to change the info of "song1.mp3" to anything via a text feild

my host supports php, and mysql, but i dont know how to use databases

help plz

thx in advance

Posted: Thu Oct 27, 2005 3:43 pm
by Burrito
take a look at fwrite() to write out the txt file.

if you need help on saving the info to a db let me know and I'll provide you some guidance as to how to connect and interact with a mysql db.