isLogin(); $attachid = intval ( $_GET ['id'] ); $stredit = $new ['attach']->find ( 'attach', array ('attachid' => $attachid ) ); $stredit['content'] = tsDecode($stredit['content']); if($stredit=='') { tsNotice('NO!'); } if($userid!=$stredit['userid']) { tsNotice('NO'); } include template ( "edit" ); ?>