Pass input arrays into GetOutputEditoValues() and CheckOutputEditorInput(). We don't want

classes to be hardcoded to read directly from $_REQUEST
This commit is contained in:
Chris Morgan
2006-07-08 22:06:28 +00:00
committed by WineHQ
parent 4708101f01
commit f05c05864e
13 changed files with 85 additions and 153 deletions

View File

@@ -245,19 +245,13 @@ class Note {
}
/* retrieves values from $_REQUEST that were output by OutputEditor() */
function GetOutputEditorValues()
/* $aValues can be $_REQUEST or any array with the values from OutputEditor() */
function GetOutputEditorValues($aValues)
{
$aClean = array(); //array of filtered user input
$aClean['iVersionId'] = makeSafe($_REQUEST['iVersionId']);
$aClean['iAppId'] = makeSafe( $_REQUEST['iAppId']);
$aClean['sNoteTitle'] = makeSafe($_REQUEST['sNoteTitle']);
$aClean['sNoteDesc'] = makeSafe($_REQUEST['sNoteDesc']);
$this->iVersionId = $aClean['iVersionId'];
$this->iAppId = $aClean['iAppId'];
$this->sTitle = $aClean['sNoteTitle'];
$this->sDescription = $aClean['sNoteDesc'];
$this->iVersionId = $aValues['iVersionId'];
$this->iAppId = $aValues['iAppId'];
$this->sTitle = $aValues['sNoteTitle'];
$this->sDescription = $aValues['sNoteDesc'];
}
}
?>