Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(isset($_GET['q'])) {
- $query = $_GET['q'];
- } else {
- echo 'Please set Query ID';
- exit;
- }
- if(is_file('text_files/' . $query . '.txt')) {
- $text_file = file_get_contents('text_files/' . $query . '.txt');
- } else {
- echo 'No such ID!';
- exit;
- }
- var_dump($text_file);
- echo 'Successfully retrieved text file!';
- exit;
Advertisement
Add Comment
Please, Sign In to add comment