ZF-2941: retrieve the messages a validator is using

Issue Type: Patch Created: 2008-03-21T13:00:25.000+0000 Last Updated: 2009-03-13T13:42:38.000+0000 Status: Resolved Fix version(s): - 1.8.0 (30/Apr/09)

Reporter: Alexander Lanin (alexl) Assignee: Thomas Weidner (thomas) Tags: - Zend_Validate

Related issues: - ZF-4371



Currently there is no way to retrieve the messages a validator is using

I can't think of any simple example right now, but anyway a getMethod doesn't hurt, does it?

I'm using this to obtain the keys of this array, someone else might need the values (and keys)

<pre class="highlight">Index: Validate/Abstract.php
--- Validate/Abstract.php   (revision 8963)
+++ Validate/Abstract.php   (working copy)
@@ -99,6 +99,10 @@
         return $this->_messages;
+    public function getMessageTemplates() {
+       return $this->_messageTemplates;
+    }
      * Returns an array of the names of variables that are used in constructing validation failure messages


Posted by Wil Sinclair (wil) on 2008-03-25T22:02:50.000+0000

Resetting 'fix version priority' and 'fix version' to be re-evaluated for next release.

Posted by Thomas Weidner (thomas) on 2009-03-13T13:42:37.000+0000

Feature added with r14317.

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.