session_start(); $document = array(); $script = ""; $init = ""; require "../lib/getnpost.php"; require "../lib/config.php"; require "../lib/dbconnect.php"; require "../lib/auth.php"; require "../lib/common.php"; require "community_common.php"; function mkEdit( &$document, &$script, &$init, $bdid, $page, $msid, $sn, $ss, $sc, $st ) { global $PsycheAdmin; global $mscatarray; $ste = urlencode($st); $result = mysql_query("select us.usname, ms.msname, ms.mstime, ms.msread, ms.mscat, ms.msdepth, ms.mssubject, ms.mscontent, ms.msattaches from messages as ms left join users as us on ms.usid = us.usid where ms.msid = '$msid'"); list($usname, $msname, $mstime, $msread, $mscat, $msdepth, $mssubject, $mscontent, $msattaches) = mysql_fetch_row($result); if (!$usname) $usname = $msname; $mscontent = str_replace("", "", $mscontent); if ($msdepth) { $mscatstring = << EOS; $mscatscript = ""; } else { $somsca = sizeof($mscatarray); $mscatstring = << Á¾·ù EOS; $mscatSelected = array(); $mscatSelected[$mscat] = " selected=\"selected\""; for ($i = 0; $i < $somsca; $i++) { $mscatstring .= <<{$mscatarray[$i][1]} EOS; } if ($PsycheAdmin) { $mscatstring .= <<°øÁö EOS; } $mscatstring .= << EOS; $mscatscript = <<»èÁ¦] EOS; $atidx++; } } $msattachmax = $atidx + 1; $document['main'] .= << {$document['caption']} $mscatstring $usname ($mstime, Hit: $msread) $attachstring $mscontent EOS; $script .= <<