Location: PHPKode > projects > Work project > workproject/include_state_prospect.inc
<?
function stateprospect_desc  ($state_id) {

	global $g_database_name;
	
	if ($state_id != "") {
		$result_state = mysql($g_database_name ,
		"SELECT STATE_PROSPECT_DESC FROM STATE_PROSPECT WHERE STATE_PROSPECT_ID=$state_id") or die("state name of selected task not found");
		$state_prospect_desc = mysql_result($result_state,0,STATE_PROSPECT_DESC);
		mysql_free_result($result_state);
	} else {
		$state_prospect_desc = "not assigned state name";
	}
	return $state_prospect_desc;
}
?>
Return current item: Work project