function within a class function

From: Date: Sun, 20 Jun 2010 23:45:52 +0000
Subject: function within a class function
Groups: php.general 
Request: Send a blank email to php-general+get-306276@lists.php.net to get a copy of this message
Within a class function I have defined another function for use with the usort() function. How do I reference it? When it's not part of a class usort($arr,"cmp") works fine but when it's within a class function I get this error: PHP Parse error: syntax error, unexpected T_STRING, expecting T_FUNCTION Is it not in the scope of the class function? -- "Memory is like an orgasm. It's a lot better if you don't have to fake it." -- Seymour Cray (on virtual memory) Rick Pasotto rick@niof.net http://www.niof.net

« previous php.general (#306276) next »