【发布时间】:2011-12-24 15:23:41
【问题描述】:
我创建了一个用于在 CakePHP 中安装应用程序的插件。在我的插件文件夹中,我创建了文件夹结构:
/app
/Plugin
/Install
/Controller
/Component
/Model
/Behavior
/View
/Helper
/Install
/Layouts
/Installer.ctp
/webroot
/css
default.css
现在在我的 Installer.ctp 中,我输入了该代码:
<?php
echo $this->Html->css('/Install/default.css');
?>
但是 CakePHP 会返回给我的 URL /cp/Install/default.css
知道如何让插件从插件文件夹 webroot 中加载正确的文件吗?
【问题讨论】:
标签: cakephp plugins cakephp-2.0