zend-framework

How to pass request variables like controller and action to Zend Studio debugger (zend-debugger)?

Hi, it's the first time I use Zend Studio to debug an application and I'm a little bit lost on how to specify request parameters when debugging as a php script. ...

How to swap Login for Logout after a user logs in using Zend_Navigation?

I'm using an XML config file to populate my navigation using Zend_Navigation. I have Login and Logout in the navigation, but obviously I should only display the 1 action that makes sense. I believe I can do something like $navigation->removePage() but... How do I get the $navigation variable in a Controller after it was previously crea...

Zend Form validator is not triggered

Hello Everyone, I am trying to get my UniqueEmail validator working but it seems that my validator is never triggered. This is my form: class EventManager_Form_User_Base extends SF_Form_Abstract{ public function init(){ $this->addElementPrefixPath( 'EventManager_Validate', APPLICATION_PATH . '/modules/eventManage...

Zend Framework Application - Showing 404 Error Pages / Generic Error Pages in Production Mode and showing Exceptions in Development Mode

Hi all, My goal is to achieve the following; in any environment, Production, Testing or Development, the application can have 2 modes: Production Mode and Debug Mode. Currently, I have it setup so that the config.ini has this setting. No issues with that. The problem comes when I want to achieve the following: If the Production Mode i...

Lucene index with multiple fields of the same nature

Each Lucene doc is a recipe, and each of these recipes have ingredients. Im working towards being able to search the ingredients and give a result that says two ingredients matched out of four. (for example) So how can I add the ingredients to the doc? In solr I can just create multiple fields of and it would save them all, I might be...

How to wrap Zend_Form error message in custom html?

Hi, I need to wrap zend form error messages in custom html. <div class="cerror" id="ID-error"> <div class="ui-widget"> <div class="ui-state-error ui-corner-all" id="IDerror-msg"> %ZEND_FORM_ERROR_MESSAGE% </div> </div> </div> Now I get errors in format: <ul> <li>Error message</li> </ul> I nee...

Zend Sessions getting mixed up

I'm currently working on the login for a Zend Framework application, and I'm using a combination of Zend_Auth and Zend_Session using a database adapter (as described in the Zend Framework manuals). I've made a resource for the session: class DC_Resource_DbSession extends Zend_Application_Resource_ResourceAbstract{ public function init...

Using Zend_Controller_Router_Route to create friendly URLs for the actions in IndexController

In my IndexController, I currently have indexAction (homepage), loginAction and logoutAction. I'm trying to remove "/index/" from the URL to get domain.com/login instead of domain.com/index/login. What is the cleanest way to achieve this? Is there a RegEx we can use? I don't ever want /index/ in the URL. My current solution, which I...

Zend Cache not working using Action Helper

Hi, I'm trying to implement full page static caching in my Zend Framework application. Using the Static backend coupled with the Capture frontend, whole pages can be cached, and served by a .htaccess redirect in the future, until the cache is deleted/regenerated. For reference, I've been using the section on Zend_Cache_Backend_Static in...

Zend_Form and Zend_Filter

How to disable filtering in Zend_Form before its re-populating? ...

Starting with Zend Tutorial - Zend_DB_Adapter throws Exception: "SQLSTATE[HY000] [2002] No such file or directory"

Hey there, i start learning Zend Framework with the Book "Zend Framework in Action" in German. Right there where it start to get interesting my PHP Unit Test throws this Error: "Zend_Db_Adapter_Exception: SQLSTATE[HY000] [2002] No such file or directory" I cant find any hints at google. I did everything like in the book. Can anyone gi...

Zend_Form Creation for Propel Objects

I'm currently working on a project where I use Zend Framework with Propel. I'm looking for something that'll create Zend_Forms for Propel objects, preferably in a similar way to django's modelforms Is there anything out there that does this already, and if not, what would be the best way to go about creating something like this? ...

Probable reasons why autoloading wont work in Zend Framework 1.10.2 ?

Iam writing an application using Zend Framework 1.10.2. I created few model classes and a controller to process them. When Iam executing my application and accessing the admin controller. Iam seeing this error. Fatal error: Class 'Application_Model_DbTable_Users' not found in C:\xampp\htdocs\bidpopo\application\controllers\AdminCon...

How do I include Zend Framework libraries in my domain?

Locally, on my xampp installation, the Zend folder is under PEAR\Zend, and Pear is in the include path. So when I do require_once "Zend\Date.php" there is no problem. However, on my domain (Hostmonster), that's not the case. I have no idea where the Zend folder is, although doing phpinfo(); seems to indicate that Zend Framework is defi...

Best way to deal with Zend for Element hinting?

ex. <Form> <input type="text"/> <span style="display block">your text should be between 4-8 chars</span> </form> anyhow just need some kind of pregenerated hint message so I can show hint using JS(Jquery) afterwile what is best way to deal , extending the parent class or is there some other way? ...

What is the best way to use Email Template in Zend/PHP

I am working on a website where Users create their accounts. I need to send email to users on many oceans. For example when signup, forgot password, order summary etc. I want to use emails templates for this. I need your suggestions for this. I want to use a way that If I change any email template or login in less time and changes. I ha...

"IS NULL" in Zend_Db_Table select not working

I'm trying to do a join on 2 tables in Zend, using the DbTable / model / mapper structure. If, in my mapper, I do this: $select = $this->getDbTable()->select(Zend_Db_Table::SELECT_WITH_FROM_PART) ->setIntegrityCheck(false) ->join('images', 'images.oldFilename = availablePict...

Zend Framework Problem

Hi, i get sometimes this error: Fatal error: Uncaught exception 'Zend_Session_Exception' with message 'session has already been started by session.auto-start or session_start()' in /www/htdocs/w00a1ed7/autospin/redaktion/library/Zend/Session.php:462 Stack trace: #0 /www/htdocs/w00a1ed7/autospin/redaktion/library/...

How to get the current time/timezone of the user visiting my website?

I am working on an application which utilizes PHP (Zend Framework) and JavaScript (jQuery). I'm trying to get the current time of the user visiting the site. Is this possible? How can this be done? ...

Add 1 Page to each PDF in folder

I have a folder with 100s of PDF versions of PPT presentations. I also have a one page PDF file that I want to add to the beginning of each PDF file. Is there a way I can do this with PHP? Could I maybe use the Zend Framework? ...