[FX.php List] checkboxes

Gjermund Gusland Thorsen ggt667 at gmail.com
Sat Oct 21 02:49:30 MDT 2006


an unchecked checkbox will not be sent on the form neither as
formFieldName= or ""
If a check box is unchecked not even the name of that checkbox will be
sent to the next page.

So all checkbox names should be parsed on the parsing page, something like this:
if( isset( $_REQUEST['myStatusField'] ) ) {
$q->AddDBParam( 'myStatusField', $_REQUEST['myStatusField'] );
} else {
$q->AddDBParam( 'myStatusField', '0' );
}

ggt667

On 10/21/06, FHASELTINE at aol.com <FHASELTINE at aol.com> wrote:
> checkboxes
>
>  Erik comment on check boxes
>  "In my experience, when a check box is unchecked, the form field does
>  not get posted."
>
>  I cannot comment about the past, but my checkboxes got posted to the
> appropriate fields. the fields only had a choice between "checked" and "".
>  Anyways it works well.
>  Florence Haseltine
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
>
>
>


More information about the FX.php_List mailing list