how to remove "Invalid" string in properties
- From: "Jason" <judgej (at) xaraya.com>
- Date: Sat, 18 Nov 2006 15:35:15 -0000
"linoj" <jonthan (at) parkerhill.com> wrote in message
news:ejgoc2$oq5$1 (at) newton.xaraya.com...
> Why do all properties have the word "Invalid " pre-pended to every
> validation message. What if i dont want that word??? and i dont!
>
> Unfortunately, its done in just about every Dynamic property php file, in
> the showInput function, and showInput then loads the property's template
> directly. So there's no way to intercept it at a single point.
>
> I'd have to override every property xd file that I use.
>
> Or, I'm wondering if there were a way to make the pre-pended string a
> configuration variable that's then used in the showInput function. But if
> so, where would it go? the DD module does not have an admin config screen.
>
> I'd appreciate suggestions, especially a least intrusive one. I'm working
> in 1.x mtn code on this. (Is this situation in 2x too?)
Do you mean this code fragment?
...
$data['invalid'] =!empty($this->invalid) ? xarML('Invalid #(1)',
$this->invalid) : '';
return xarTplProperty('dynamicdata', 'objectref', 'showinput', $data,
$template);
...
If so, then good question - no idea why it does that. I expect it is just a
case of copy-and-paste from a very early property.
Raise a bug, then we can see about removing it if there are no objections.
-- JJ
_______________________________________________
Xaraya_devel mailing list
Xaraya_devel (at) xaraya.com
http://xaraya.com/mailman/listinfo/xaraya_devel