BRADERY Posted October 25, 2010 Share Posted October 25, 2010 for($i=0; $i!=count($account_data); $i++){ echo "\n::: ".strtoupper($account_data[$i][0])." :::\n"; if($account_data[$i][1] != "" && stristr($account_data[$i][0], "@") && stristr($account_data[$i][0], ".")){ list($place[0],$place[1],$place[2],$place[3]) = authorize($account_data[$i], $game_link); if($place[2] > 1 && strlen($place[3]) == 40){ $filename = 'auth-keys.txt'; $fp = file($filename,'a+'); $data = $place[2]." ".$place[3]."\r\n"; file_put_contents($filename, $data, FILE_APPEND); echo $data; } else echo "Account Skipped: wrong password/email combo, or a login error...\n"; $echo = file_put_contents($filename, FILE_APPEND); } else echo "Account Skipped: invalid email or blank password...\n"; } echo "\n::: PROGRAM FINISHED, YOU CAN CLOSE THIS AT ANY TIME :::"; sleep(10000); You see where I tried to put $echo file_put_contents etc... On success the acct writes a security id and a security auth key to a file, ever acct puts the tokens on a new line every acct... now when an acct echos account skipped, how can I make it print the echo on the file new line instead of nothing being writen and it just skipping the account Link to comment https://forums.phpfreaks.com/topic/216833-ok-i-need-some-help-writing-echo-to-the-file/ Share on other sites More sharing options...
BRADERY Posted October 26, 2010 Author Share Posted October 26, 2010 bump Link to comment https://forums.phpfreaks.com/topic/216833-ok-i-need-some-help-writing-echo-to-the-file/#findComment-1126451 Share on other sites More sharing options...
trq Posted October 26, 2010 Share Posted October 26, 2010 else $skipped = "Account Skipped: wrong password/email combo, or a login error...\n"; echo $skipped; $echo = file_put_contents($filename, $skipped, FILE_APPEND); Link to comment https://forums.phpfreaks.com/topic/216833-ok-i-need-some-help-writing-echo-to-the-file/#findComment-1126539 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.