mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-27 10:23:28 +01:00
use csv_split on options of text field, to allow to enclose preg in quote to allow comma in it
This commit is contained in:
parent
ff4152dd42
commit
03c21735e6
@ -1267,12 +1267,12 @@ class etemplate extends boetemplate
|
||||
{
|
||||
$value = is_numeric($pre) ? self::number_format($value,$pre,$readonly) : sprintf($pre,$value);
|
||||
}
|
||||
$cell_options .= ',,'.($cell['type'] == 'int' ? '/^-?[0-9]*$/' : '/^-?[0-9]*[,.]?[0-9]*$/').',number';
|
||||
$cell_options .= ',,'.($cell['type'] == 'int' ? '/^-?[0-9]*$/' : '"/^-?[0-9]*[,.]?[0-9]*$/"').',number';
|
||||
// fall-through
|
||||
case 'hidden':
|
||||
case 'passwd':
|
||||
case 'text': // size: [length][,maxLength[,preg[,html5type]]]
|
||||
$cell_opts = $c = explode(',',$cell_options);
|
||||
$cell_opts = $c = self::csv_split($cell_options); // allows to enclose preg in quote to allow comma
|
||||
// fix preg, in case it contains a comma (html5type is only letters and always last option!)
|
||||
if (count($cell_opts) > 3)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user