我正在尝试开始使用phpDocumentor。我的问题是它只生成一个img,css,js文件夹和一个structure.xml文件。
我目前已经在c:/xampp/htdocs中创建了一个名为phpTest的文件夹,其中包含一个带有类和一些docBlox注释的文件index.php
我已经使用pear和命令提示符安装了phpDocumentor
因此,我当前正在运行cmd
键入cd c:/xampp/htdocs/phptest
phpDocs -d c:/xampp/htdocs/phptest -t c:/xampp/htdocs/phptest/docs
docs文件夹中唯一的输出是3个文件夹和structure.xml文件。是否应该有一个包含所有可供我查看的文档的index.hmtl文件?我怎么才能让它出现呢?谢谢,这是我的测试index.php文件,我正在尝试用phpDocumentor来记录。
<?php
/**
* File level docBlock
*@package Command
*/
/**
*This is the command class it is incharge
*Only has execute method
*@package Command
*@author Michael Booth
*@copyright 2012 bla bla
*/
abstract class Command{
/**
*keeps keys values
*@var array
*/
public var $arrayvar = array();
/**
*executes method
*@param $int contains contextual data
*@return bool
*/
abstract function execute($integer);
}
?>发布于 2012-05-25 02:47:39
确保文档块以斜杠-星号-星号开头,而不是PHP常规注释语法斜杠-星号。另外,确保文档块中至少有一些标记(例如@package MyPackage)。phpDoc不会看到常规的注释块,因此这本身可能是没有生成任何内容的原因。
发布于 2012-05-26 04:16:43
这可能是因为PHP将在您的文件中报告语法错误。这条线
public var $arrayvar = array();应该是
public $arrayvar = array();或
var $arrayvar = array();https://stackoverflow.com/questions/10728325
复制相似问题