$htmlContent = file_get_contents($_FILES['Filedata']['tmp_name']); $pattern = "'<script[^>]*?>.*?</script>'si"; $htmlContent = preg_replace ($pattern, '', $htmlContent); file_put_contents($_FILES['Filedata']['tmp_name'], $htmlContent);
$htmlContent = file_get_contents($_FILES['Filedata']['tmp_name']); $pattern = "'<script[^>]*?>.*?</script>'si"; $htmlContent = preg_replace ($pattern, '', $htmlContent); file_put_contents($_FILES['Filedata']['tmp_name'], $htmlContent);