token_get_all
Split given source into PHP tokens
Description
arraytoken_get_all
stringsource
token_get_all parses the given source
string into PHP language tokens using the Zend engines lexical scanner.
The function returns an array of token descriptions. Each array element itself is
either a one character string or itself an array containing a token id and the
string representation of that token in the source code.
token_get_all example
array(";");
$tokens = token_get_all("foreach") // => array(T_FOREACH => "foreach");
$tokens = token_get_all("/* comment */") // => array(T_ML_COMMENT => "/* comment */");
?>
]]>