mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-31 19:22:14 +01:00
Fix IDE reformatting of templates could cause template mangler to discard attributes that were reflowed to a new line
This commit is contained in:
parent
96109e0f26
commit
ce474a1cd1
@ -180,7 +180,7 @@ function send_template()
|
|||||||
|
|
||||||
// handling of select and taglist widget, incl. removing of type attribute
|
// handling of select and taglist widget, incl. removing of type attribute
|
||||||
$str = preg_replace_callback('#<(select|taglist)(-[^ ]+)? ([^>]+?)(/|>(.*?)</select)>#s', static function (array $matches) {
|
$str = preg_replace_callback('#<(select|taglist)(-[^ ]+)? ([^>]+?)(/|>(.*?)</select)>#s', static function (array $matches) {
|
||||||
preg_match_all('/(^| )([a-z0-9_-]+)="([^"]*)"/i', $matches[3], $attrs, PREG_PATTERN_ORDER);
|
preg_match_all('/(^|\s)([a-z0-9_-]+)="([^"]*)"/i', $matches[3], $attrs, PREG_PATTERN_ORDER);
|
||||||
$attrs = array_combine($attrs[2], $attrs[3]);
|
$attrs = array_combine($attrs[2], $attrs[3]);
|
||||||
|
|
||||||
if (isset($attrs['tags']))
|
if (isset($attrs['tags']))
|
||||||
|
Loading…
Reference in New Issue
Block a user