José,
>Logical implies a => ba is true if b is true, false in other case.
>Then this is a simple example form:
>(* is obligatory)
>*name: ___
>*surname:
>send by postal mail: [X] <-- checkbox
>postal address: ___
>
>So, if I check "send by postal mail", impl
Jörn Zaefferer escribió:
SeViR schrieb:
Somewhere in the documentation you should find a comment stating that
the temptation to add a regex method is great, but should be resisted.
I still think that its better to add custom methods that implement
those regular expression instead of one gene
Jörn,
>I like the idea.Gonna test if that works out.
>
>About the xor-validation, I wonder if this could work:
>
>$.validator.addMethod('xor', function(value, element, parameter) {
> return value && $(parameter).is(":blank");
>});
>
>rules: {
> field1: { xor: "#field2" },
> fiel
Dan G. Switzer, II schrieb:
Aaron,
I may be misunderstanding something, but what does this do that
$.validator.addMethod[1] doesn't?
The addMethod would accomplish the same thing. The addMethod() is really
affective for building a library of reusable validation method.
However, ther
Aaron,
>I may be misunderstanding something, but what does this do that
>$.validator.addMethod[1] doesn't?
The addMethod would accomplish the same thing. The addMethod() is really
affective for building a library of reusable validation method.
However, there are times when you have very specifi
I may be misunderstanding something, but what does this do that
$.validator.addMethod[1] doesn't?
[1]
http://jquery.bassistance.de/api-browser/plugins.html#jQueryvalidatoraddMethodStringFunctionString
On 4/19/07, Dan G. Switzer, II <[EMAIL PROTECTED]> wrote:
Jörn,
>Sorry, my example was a bi
Jörn,
>Sorry, my example was a bit misleading. So far you can't pass a function
>as a rule, only as a value to required.
>supported: field: { required: function() {} }
>not supported: field: function() {}
>
>By adding support for the latter, you could do almost everything, but
>I'm not yet sure h
SeViR schrieb:
I would need some methods ("rules" in YAV) in Validation plugin:
// generic regexp method
$.validator.addMethod("regexp", function(value, element,
regular_expression) {
return (typeof(regular_expression) == "string")?
value.match(new RegExp(regular_expression)) :
val
Dan G. Switzer, II schrieb:
Jörn,
You can do that already. After implementing the suppurt for expressions,
support for plain functions was really easy. I can imagine adding a
method on the fly:
rules: {
field2: function() { return condition; }
}
I wasn't aware of that. Howev
I would need some methods ("rules" in YAV) in Validation plugin:
// generic regexp method
$.validator.addMethod("regexp", function(value, element,
regular_expression) {
return (typeof(regular_expression) == "string")? value.match(new
RegExp(regular_expression)) : value.match(regular_e
Jörn,
>You can do that already. After implementing the suppurt for expressions,
>support for plain functions was really easy. I can imagine adding a
>method on the fly:
>
>rules: {
> field2: function() { return condition; }
>}
I wasn't aware of that. However, if you changed that do:
rules
Dan G. Switzer, II schrieb:
Jörn,
This would make field2 required only if field1 is blank:
rules: {
field2: { required: "#field1:blank" }
}
But I can't express that either field1 or field2 is required. How would
I express that using pre/post-condition and implies?
I was thinking a
Dmitrii 'Mamut' Dimandt schrieb:
Jörn Zaefferer wrote:
Dmitrii 'Mamut' Dimandt schrieb:
Jörn Zaefferer wrote:
I'm gonna take a look at that library for some inspiration. And maybe
copy some validation methods (called rules at yav).
Let me know if you have any specific reques
>
> I guess what you want is something like:
>
> rules[1]='field1|equal||pre-condition';
> rules[2]='field2|regexp|^a-zA-Z$|post-condition';
> rules[3]='1|implies|2|Enter either field 1 or field 2';
>
> rules[4]='field2|equal||pre-condition';
> rules[5]='field1|regexp|^a-zA-Z$|post-condition';
>
Jörn,
>This would make field2 required only if field1 is blank:
>
>rules: {
> field2: { required: "#field1:blank" }
>}
>
>But I can't express that either field1 or field2 is required. How would
>I express that using pre/post-condition and implies?
I was thinking about this the other day, and I
Jörn Zaefferer wrote:
>
> Dmitrii 'Mamut' Dimandt schrieb:
>> Jörn Zaefferer wrote:
>>
>>> I'm gonna take a look at that library for some inspiration. And maybe
>>> copy some validation methods (called rules at yav).
>>>
>>> Let me know if you have any specific requests for the jQuery
>>> valida
Dmitrii 'Mamut' Dimandt schrieb:
Jörn Zaefferer wrote:
I'm gonna take a look at that library for some inspiration. And maybe
copy some validation methods (called rules at yav).
Let me know if you have any specific requests for the jQuery
validation plugin.
That would be the pre-condi
Jörn Zaefferer wrote:
> I'm gonna take a look at that library for some inspiration. And maybe
> copy some validation methods (called rules at yav).
>
> Let me know if you have any specific requests for the jQuery
> validation plugin.
>
That would be the pre-condition, implies and post-condition. T
SeViR schrieb:
Dmitrii 'Mamut' Dimandt escribió:
SeViR wrote:
Wow. Thank you for the link to YAV, http://yav.sourceforge.net/ that I
found on the university site. This is amazing!
YAV is a fantastic JavaScript Form Validation library with a pair of
years
of develop. By now, we use this l
This is excellent news, Jose. Me alegro tanto que ha decidido utilizar
jQuery! :)
We look forward to seeing the results of your projects and contributions
to the jQuery effort.
Thanks again!
Rey Bango
jQuery Project Team
SeViR wrote:
Hi there,
recently I presented a seminar of JavaScri
Congrats, Jose Francisco. jQuery FTW!
On 4/19/07, SeViR <[EMAIL PROTECTED]> wrote:
Dmitrii 'Mamut' Dimandt escribió:
> SeViR wrote:
>
> Wow. Thank you for the link to YAV, http://yav.sourceforge.net/ that I
> found on the university site. This is amazing!
>
YAV is a fantastic JavaScript Form V
Dmitrii 'Mamut' Dimandt escribió:
SeViR wrote:
Wow. Thank you for the link to YAV, http://yav.sourceforge.net/ that I
found on the university site. This is amazing!
YAV is a fantastic JavaScript Form Validation library with a pair of years
of develop. By now, we use this library in join
SeViR wrote:
>
> Hi there,
>
> recently I presented a seminar of JavaScript programming with jQuery
> in The University of Murcia (Spain) and the results are very good.
>
> http://www.um.es/atica/mncs/forja (sorry in *spanish*)
Wow. Thank you for the link to YAV, http://yav.sourceforge.net/ that
23 matches
Mail list logo