isLoggedIn()) { apidb_header("Please login"); echo "To submit a comment for an application you must be logged in. Please login now or create a new account.","\n"; exit; } // the user submitted his comment if(!empty($aClean['sBody'])) { // create a new comment $oComment = new Comment(); $oComment->sSubject = $aClean['sSubject']; $oComment->sBody = $aClean['sBody']; $oComment->iParentId = $aClean['iThread']; $oComment->iVersionId = $aClean['iVersionId']; $oComment->create(); $oVersion = new version($oComment->iVersionId); util_redirect_and_exit($oVersion->objectMakeUrl()); // let's show the comment form } else { apidb_header("Add Comment"); $mesTitle = "Post New Comment"; if($aClean['iThread'] > 0) { $hResult = query_parameters("SELECT * FROM appComments WHERE commentId = '?'", $aClean['iThread']); $oRow = query_fetch_object($hResult); if($oRow) { $mesTitle = "Replying To ... $oRow->subject\n"; echo html_frame_start($oRow->subject,500); echo htmlify_urls($oRow->body), "

\n"; echo html_frame_end(); } } echo "

Enter your comment in the box below."; echo "
Please do not paste large terminal or debug outputs here.

"; echo "
\n"; echo html_frame_start($mesTitle,500,"",0); echo '',"\n"; echo "\n"; echo " \n"; echo "\n"; echo " \n"; echo "\n"; echo "\n"; echo "
From:  ".$_SESSION['current']->sRealname."
Subject:  
\n"; echo " \n"; echo " \n"; echo "
\n"; echo html_frame_end(); echo "\n"; echo "\n"; echo "\n"; echo "
"; } apidb_footer(); ?>