in reply to default values of textareas using CGI.pm
Another note The default values that you specify for the forms are only used the first time the script is invoked (when there is no query string). On subsequent invoca- tions of the script (when there is a query string), the former values are used even if they are blank. If you want to change the value of a field from its previ- ous value, you have two choices: (1) call the param() method to set it. (2) use the -override (alias -force) parameter (a new fea- ture in version 2.15). This forces the default value to be used, regardless of the previous value: print $query->textfield(-name=>'field_name', -default=>'starting value', -override=>1, -size=>50, -maxlength=>80);
-- Randal L. Schwartz, Perl hacker
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: default values of textareas using CGI.pm
by create 3 arrays. first array last names, second name first name and third array (Initiate) on Mar 09, 2001 at 20:59 UTC |