@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
defined ( 'IN_TS' ) or die ( 'Access Denied.' );
|
||||
$userid = aac('user')->isLogin();
|
||||
|
||||
$attachid = intval ( $_POST ['attachid'] );
|
||||
|
||||
$stredit = $new ['attach']->find ( 'attach', array ('attachid' => $attachid ) );
|
||||
|
||||
if($stredit=='')
|
||||
{
|
||||
|
||||
tsNotice('NO!');
|
||||
}
|
||||
if($userid!=$stredit['userid'])
|
||||
{
|
||||
tsNotice('NO');
|
||||
|
||||
}
|
||||
|
||||
|
||||
$attachname = trim($_POST['attachname']);
|
||||
|
||||
$pay=intval($_POST['pay']);
|
||||
|
||||
$new['attach'] -> update('attach', array('attachid' => $attachid), array(
|
||||
'attachname' => $attachname,
|
||||
'pay' => $pay,
|
||||
));
|
||||
header("Location: " . tsUrl('attach', 'show', array('id' => $attachid)));
|
||||
?>
|
||||
Reference in New Issue
Block a user