Location: PHPKode > projects > Parser > parser/index.php
<html>
<body bgcolor=white>
<?
require('Parser.php');

$parser = new Parser('sample.cfg');
if ($parser->error()) {
        echo "Error: ".$parser->error()."<p>";
}

$s_list = $parser->sections();
while (list($key,$sec_name)=each($s_list)) {
        $p_list = $parser->parameters($sec_name);
        echo "$sec_name";
        echo "<ul>";
        while (list($key,$par_name)=each($p_list)) {
                $val = $parser->param($sec_name,$par_name);
                echo "$par_name => $val<br>";
        }
        echo "</ul>";
}


?>
</body>
</html>
Return current item: Parser