时间:2021-07-01 10:21:17 帮助过:3人阅读
save_file.php:
<?php session_start(); $handle = fopen($_POST['original_file_name'], "w"); $text = $_POST['file_contents']; if(fwrite($handle, $text) == FALSE){ $_SESSION['error'] = 'There was an error'; }else{ $_SESSION['error'] = 'File edited successfully'; } fclose($handle); header("Location: ".$_POST['page']); ?>
read_file.php:
Untitled Document
希望本文所述对大家的php程序设计有所帮助。