ZenMagick 0.9.8


org.zenmagick.store.mvc.validation.ZMUniqueEmailRule
\store\mvc\validation\ZMUniqueEmailRule.php at line 31

Class ZMUniqueEmailRule

ZMObject
└─ZMRule
└─ZMUniqueEmailRule

public class ZMUniqueEmailRule
extends ZMRule

Check for unique email address.

Author:
DerManoMann
Version:
$Id: ZMUniqueEmailRule.php 2694 2009-12-03 22:32:18Z dermanomann $

Constructor Summary

ZMUniqueEmailRule(string name, string msg)

Create new required rule.

Method Summary
string

toJSString()

Create JS validation call.

boolean

validate(ZMRequest request, array data)

Validate the given request data.

Methods inherited from org.zenmagick.mvc.validation.ZMRule
getDefaultMsg, getErrorMsg, getJSName, getMsg, getName, setDefaultMsg, setMsg, setName, toJSString, validate
Methods inherited from org.zenmagick.core.ZMObject
attachMethod, get, getAttachedMethods, getPropertyNames, set, singleton

Constructor Detail

\store\mvc\validation\ZMUniqueEmailRule.php at line 39

ZMUniqueEmailRule

public ZMUniqueEmailRule(string name, string msg)

Create new required rule.

Parameters:
name - The field name.
msg - Optional message.

Method Detail

\store\mvc\validation\ZMUniqueEmailRule.php at line 68

toJSString

public string toJSString()

Create JS validation call.

Returns:
Formatted JavaScript .

\store\mvc\validation\ZMUniqueEmailRule.php at line 58

validate

public boolean validate(ZMRequest request, array data)

Validate the given request data.

Parameters:
request - The current request.
data - The data.
Returns:
true if the value for $name is valid, false if not.

ZenMagick 0.9.8