Prevent ProfileField fieldNames from containing spaces. They cause problems with JS in some kinds of form fields. Fixes bug #11371.
This commit is contained in:
parent
138eb3140c
commit
077f29fff0
4 changed files with 16 additions and 15 deletions
|
|
@ -150,6 +150,7 @@ sub create {
|
|||
$properties->{fieldType} ||= "ReadOnly";
|
||||
return undef if $class->exists($session,$fieldName);
|
||||
return undef if $class->isReservedFieldName($fieldName);
|
||||
return undef if $fieldName =~ m{\s};
|
||||
|
||||
### Data okay, create the field
|
||||
# Add the record
|
||||
|
|
|
|||
|
|
@ -57,10 +57,10 @@ our $I18N = {
|
|||
lastUpdated => 1036964807
|
||||
},
|
||||
|
||||
'475 description' => {
|
||||
message => q|The name of the field, used internally in the database.|,
|
||||
lastUpdated => 1122316558,
|
||||
},
|
||||
'475 description' => {
|
||||
message => q|The name of the field, used internally in the database. Field names may not contain spaces. Certain field names are reserved, such as "op", "func", "username", "shop", "karma", "status", "lastUpdated", "dateCreated".|,
|
||||
lastUpdated => 1264448486,
|
||||
},
|
||||
|
||||
'472 description' => {
|
||||
message => q|A short, descriptive label displayed to the user. This can be a call to WebGUI's
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue