$bit) { $threadstatus = setstatus(13 - $i, $bit, $threadstatus); } C::t('forum_thread')->update($values['tid'], array('status' => $threadstatus)); } $posttable = getposttablebytid($values['tid']); $poststatus = DB::result_first("SELECT status FROM ".DB::table($posttable)." WHERE pid='$values[pid]'"); $poststatus = setstatus(4, 1, $poststatus); if(!empty($_POST['allowlocal'])) { $poststatus = setstatus(6, 1, $poststatus); } if(!empty($_POST['allowsound'])) { $poststatus = setstatus(7, 1, $poststatus); } if(!empty($_POST['mobiletype']) && $_POST['mobiletype'] < 8) { $mobiletype = base_convert($_POST['mobiletype'], 10, 2); $mobiletype = sprintf('%03d', $mobiletype); for($i = 0;$i < 3;$i++) { $poststatus = setstatus(10 - $i, $mobiletype{$i}, $poststatus); } } C::t('forum_post')->update('tid:'.$values['tid'], $values['pid'], array('status' => $poststatus)); if($_POST['location']) { list($mapx, $mapy, $location) = explode('|', dhtmlspecialchars($_POST['location'])); C::t('forum_post_location')->insert(array( 'pid' => $values['pid'], 'tid' => $values['tid'], 'uid' => $_G['uid'], 'mapx' => $mapx, 'mapy' => $mapy, 'location' => $location, )); } } } function output() { global $_G; $variable = array( 'tid' => $_G['tid'], 'pid' => $GLOBALS['pid'], 'noticetrimstr' => $GLOBALS['noticetrimstr'], ); mobile_core::result(mobile_core::variable($variable)); } } ?>