Pulling data from SQL, and writing to a text file

前端 未结 7 1093
广开言路
广开言路 2021-01-07 01:28

I am trying to pull data from SQL, and then write it to a text file. This does that, to an extent, but it only pulls 1 from the table, which reads test:test<

7条回答
  •  一生所求
    2021-01-07 01:35

    Others have answered the why it is only writing one content into the file, this is more of a suggestion but if you want to record the actual user and password, instead of:

    $accounts = "$user:$pass
    ";

    use

    $accounts = $user . ":" . $pass . "\n";

    but if you already knew that and were using that for debugging purposes then disregard this.

    Good luck

提交回复
热议问题