<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Tasks</title>
<?php echo $this->html->css(array('style.css')); ?>
</head>
<body>
<?php echo $content_for_layout; ?>
</body>
</html>
在视图中的home.ctp中
<h1>Welcome!</h1>
<p>Welcome to my task management site.</p>
如何在CakePHP 2.5.5中删除此错误。
答案 0 :(得分:3)
Change $html->css(...) to $this->Html->css(...)