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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Edit/delete a line in a file

Status
Not open for further replies.

syndrome

Technical User
May 11, 2002
2
0
0
IL
I want to open a file, go to a certain line in that file(line number x) and edit or delete that line with PHP.
I'm writing a news-administration-script with wich I want to be able to edit/delete a newsmessage stored in a line of my newsfile.
Thx for solution tips,

syndrome
 
give each line a unique id and use that id to find a message.
for exmaple imagine having a title, author and text body (fields are seperated with a tab - \t)

ID\tTitle\tAuthor\tBody

1\tNews #1\tWebmaster\tToday....

better yet, use mysql :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top