我想設置一個basePath對於給定請求的我的Mvc的每個組件都是一樣的。我的意思是,當我調用這些方法我想獲得相同的結果,可以說'/spam/ham/': echo $this->headLink()->prependStylesheet($this->basePath() . '/styles.css') // $this->basePath() has to be '/spam/ham/'
在Zend框架2用戶的相冊示例性引導的模型被配置是這樣的: <?php
namespace Album;
// Add these import statements:
use Album\Model\Album;
use Album\Model\AlbumTable;
use Zend\Db\ResultSet\ResultSet;
use Zend\Db\TableGateway