Hi!
I have txt file containing something like:
User1
123434
User2
435345
User3
234234
User3
234924
Now, i need to delete one user from that txt file, along with number that is after the user
so lets say that i entered in delete form: User1 , then i would like my txt file look like:
User2
435345
User3
234234
User3
234324
I tried with deleting it by lines (delete line 1, then delete line 2, but it really didnt work properly, also i tried with str_replace($Data,"",$Handle); but didnt work at all). I want to make a form, in which i would enter the username, and press deleteor some button, and the user along with his number would get deleted (i already made aform, but i cant figure out the function)
So if aynone has an idea how i could achieve this, i would be very thankfull if they share it