There isn't an automated way to do this, you have to manually blank
the variables that the form offers before you fillFromRequest. The
reason that this hasn't been automated is that in the case of a
checkbox, the browser doesn't give any indication that it is on the
form unless it's checked. It would be nice though...
On Apr 27, 2006, at 9:06 AM, Jason Penney wrote:
> nkibodeaux@... wrote:
>> I've run into this before and it is an annoying little problem.
>> To fix
>> it, what I've done in the past is this (if memory serves):
>> 1 - Load FooWrapper from DB
>> 2 - Set every member variable in FooWrapper to NULL or empty
>> string (don't
>> remember if it makes a difference)
>> 3 - Call FooWrapper->fillFromRequest()
>> I wonder if it wouldn't be better for fillFromRequest to work this
>> automatically. Another option would be to add a clear() method to
>> DataObjectWrapper that would set everything to NULL or empty
>> string for
>> you. Does anyone else have thoughts about this?
> That will work to a degree, but fails on the cases where I offer a
> that only exposes part of a table row. I only want to blank the
> the form offered...
> Jason C Penney (jpenney@...)