使用razorflow时提示如下错误
Fatal error: Class 'RFComponent' not found in TableComponent.php on line 9
TableComponent是razorflow里自带的文件,怎么也报错了?有人遇到过吗
如下会调用TableComponent.php
<?phprequire_once("razorflow_php\lib\core\StandaloneDashboard.php");require_once("razorflow_php\lib\components\TableComponent.php");class SampleDashboard extends StandaloneDashboard { public function buildDashboard () { $table = new TableComponent('table1'); $table->setCaption("Regional Sales"); $table->setDimensions (4, 4); $table->setRowsPerPage (8); $table->addColumn('zone', "Zone"); $table->addColumn('name', "Store Name"); $table->addColumn('sale', "Sales Amount", array( "dataType" => "number", "numberPrefix" => "$ ", "textAlign" => "center" )); $data = array( array("zone" => "North", "name" => "Northern Stores", "sale" => 4000), array("zone" => "South", "name" => "Southern Stores", "sale" => 4500) ); $table->addMultipleRows($data); $this->addComponent ($table); }}$db = new SampleDashboard();$db->renderStandalone();
在线等,在线等
找到解决方法了,不用requreonce()里面的类库,所有的都会引入了