You can use the function with arguments passed by reference, like c-style programming.
example:
function getclass ($currentrow,&$returnt)
{
$class= $currentrow["CCLASS"];
$classresult = mysql_query ("SELECT * FROM CLASSLIST WHERE CLASSID =$class");
$rrow = mysql_fetch_array($classresult);
$returnf = $rrow["CLASSDESC"];
$returnt = $rrow["CLASSID"];
return $returnf;
}
$returnt = "";
$returnf = getclass($currentrow,$returnt);
now returnt contains rrow["classid"]...
For more information, look at php's manual.