Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form method='POST' action='index.php'>
- <textarea cols='85' rows='15' name='persistent_notepad'>
- <?php
- if(!file_exists("text.txt"))
- {
- $content = fopen("text.txt",'x+');
- fclose($content);
- }
- if($_POST['save'])
- {
- file_put_contents("text.txt",$_POST['persistent_notepad']);
- }
- $text = file_get_contents("text.txt");
- echo $text
- ?>
- </textarea><br>
- <input type='submit' name='save' value='Save'>
- </form>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement