| ユーザフォーラムで議論/質問 | マニュアル検索 | ハイライト | ハイライトオフ | ポータル | php spot |
Creating the parserCreating the parser –
how to create a parser using PHP code or an
XML definition file
Console_CommandLine constructorConsole_CommandLine::__construct() takes an optional array of parameters explained in the table below. Note that if you are using an XML definition file, you can pass these parameters in it (see XML example for details).
Using PHP codeThe examples below demonstrate how to instanciate Console_CommandLine and build a parser using PHP code.
The simplest way
<?php
Alternative method
<?php
Using an XML definition fileThe examples below demonstrate how to instanciate Console_CommandLine and build a parser using an XML definition file, this can be very useful if you have a big program or if you need to reuse your user interface settings for a web frontend for example. The XML file <?xml version="1.0" encoding="utf-8" standalone="yes"?> <command> <description>A useful description for your program.</description> <version>0.0.1</version> </command>
The PHP file
<?php
|
各種マニュアル:
PHPマニュアル |
PEARマニュアル |
Smarty(英語)マニュアル |
PHP-GTKマニュアル |
「Creating the parser」をGoogle検索
|