Fatal error: Class 'Products\Summary\Html\Section' not found
다음 코드에서 위의 오류가 발생합니다. Summary \ Html \ Section()이 실제로 액세스하려는 클래스의 네임 스페이스인지 확인했습니다. 왜 이것이 작동하지 않는지 전혀 모르겠다 ... 어떤 생각?치명적인 오류 : 'Products Summary Html Section'클래스를 찾을 수 없습니다.
<?php
namespace Products;
use Products\Base as ProductBase;
use Products\Mapping as MappingInterface;
use Summary\Html;
class Product1 extends ProductBase implements MappingInterface {
/**
* Complete PDF mapping
*
* @return Array
*/
public function render() {
$preTable = new Summary\Html\Section();
$row = $preTable->addRow();
$row->addColumn()->setValue('Headline one')->addClass('first');
$row->addColumn()->setValue('Headline two')->addClass('first');
return $preTable;
}
내 섹션 클래스 :이 요약은 생각처럼
namespace Summary\Html;
use Summary\Html\Element;
use Summary\Html\Section\Row;
class Section extends Element {
클래스는 명시 적으로 포함 중이거나, 오른쪽 __autoload 기능을 탑재? 확실한 질문에 대해 유감스럽게 생각하지만, 이런 종류의 것들은, 특히 오작동하는 __autoload 인 경우 그리워하기 쉽습니다. 클래스 파일의 상단에 에코 ('something')를 넣는 것이 좋습니다. – GordonM