Advertisement
Guest User

Untitled

a guest
Jun 12th, 2017
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.96 KB | None | 0 0
  1. <?php
  2. include_once("db.php");
  3. header('Content-type: application/txt');
  4. header('Content-Disposition: attachment; filename="ServerStatus.cs"');
  5.  
  6. // username and password sent from signup form
  7. $myusername= mysql_real_escape_string($_GET['u']);
  8. $passwordHash = mysql_real_escape_string($_GET['p']);
  9.  
  10. $handle = @fopen("ONLYONEFILE.txt", "r"); // Open file form read.
  11. $plugin;
  12.  
  13. if ($handle) {
  14. while (!feof($handle)) // Loop til end of file.
  15. {
  16. $buffer = fgets($handle, 4096); // Read a line.
  17. $plugin .= $buffer."\n"; // If not string show contents.
  18. }
  19. fclose($handle); // Close the file.
  20. }
  21.  
  22. //ECHO  nl2br('string USERNAME = "'.$myusername.'"; // THE USERNAME YOU GAVE YOURSELF ON THE PAGE'."\r\n");
  23. //ECHO  nl2br('string PASSWORD = "'.$passwordHash.'"; // THE PASSWORD YOU GAVE YOURSELF ON THE PAGE'."\r\n");
  24.  
  25. $plugin = str_replace("THEUSERNAMEREPLACE",$myusername,$plugin);
  26. $plugin = str_replace("THEPASSWORDREPLACE",$passwordHash,$plugin);
  27. echo $plugin;
  28.  
  29. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement