PHP fwrite new line

后端 未结 4 979
遇见更好的自我
遇见更好的自我 2020-12-03 04:36

I\'m trying to write username and password to a new line in a txt file. The output should be something like this in the txt file. I know this is not very secure but its just

4条回答
  •  我在风中等你
    2020-12-03 04:46

    How about you store it like this? Maybe in username:password format, so

    sebastion:password123
    anotheruser:password321
    

    Then you can use list($username,$password) = explode(':',file_get_contents('users.txt')); to parse the data on your end.

提交回复
热议问题