function &message_init_posting_from_post_data(&$_posting = NULL) { if (!$_posting) { $_posting = new Posting(); } $_posting->set_id($_POST['msg_id']); $_posting->set_username($_POST['username']); $_posting->set_subject($_POST['subject']); $_posting->set_body($_POST['body']); return $_posting; }