我正在学习Zend,并试图设置一个自定义视图,但我遇到了麻烦。
class AccountController extends Zend_Controller_Action
{
public function init() {}
public function indexAction()
{
$this->view->setScriptPath(APPLICATION_PATH . '/views/scripts/mobile/');
$this->view->render('iphone.phtml');
我的数据库连接有问题。我想创建一个服务作为专辑如何。创建服务时,ZF2将返回一个错误:
错误:
Zend\ServiceManager\Exception\ServiceNotFoundException
File:
/UNXDEVCKT01/www/firewall/ZendFramework/vendor/ZF2/library/Zend/ServiceManager/ServiceManager.php:496
Message:
Zend\ServiceManager\ServiceManager::get was unable to fetch or create an in
我正在尝试让我的日志写入器工作,然而,我还没有走到那一步。
当我抛出异常时:
<?php
class IndexController extends Zend_Controller_Action
{
public function indexAction()
{
throw new Exception('something bad happened!');
}
}
它不会被我的错误控制器捕获。
已检查我的版本是1.11.4与环境开发。我不知道这里出了什么问题,感谢您的帮助。我觉得这很奇怪。
( ! ) Exception: som
我试图使用以下环境为PHP应用程序设置调试:
-Clients: Windows,Zend 7,Firefox+Zend Studio工具栏
-Server: Solaris 5.1032Bits,Apache2.2.8,PHP5.2.5
我想使用Zend,因为它很容易集成到Zend中,并且具有分析能力;尽管我知道XDebug的替代方案。
问题是:我似乎找不到用于Solaris的库的最新版本。我尝试使用一个旧版本的库,不幸的是,Zend发出了以下消息:
Error while communicating with the debugger.
Possible causes:
1. The Ze
我使用Zend_Db_Table来管理我的MySQL连接。它们工作得很好,但只有一个巨大的安全问题。
如果出现错误,比如MySQL关闭,ZF会抛出一个异常,显示db连接用户名和密码。
例如,我在配置中设置了错误的db密码。这是抛出的异常。
exception 'PDOException' with message 'SQLSTATE[28000] [1045] Access denied for user 'root'@'localhost' (using password: YES)' in /Users/claudiocani