I am trying to save the $_Get, user:pass to text file in my website.
I am sorry but am not a php dev. so i've come with following code:
<?php
if( $_GET["user"] || $_GET["pass"] ) {
$file = 'somefile.txt';
file_put_contents($file, $_GET["user"] . PHP_EOL, FILE_APPEND);
file_put_contents($file, $_GET["pass"] . PHP_EOL, FILE_APPEND);
}
?>
Now it save
User
pass
How to save it as
User:pass
Thank you, regrads