mirror of
https://github.com/processwire/processwire.git
synced 2025-08-13 02:04:35 +02:00
Fix issue in InputfieldRepeater where entity encoded quotes could get confused as hex color codes for repeater item colors feature
This commit is contained in:
@@ -477,7 +477,7 @@ class InputfieldRepeater extends Inputfield implements InputfieldItemList {
|
|||||||
$wrapLabel = str_replace($matches[0], '', $wrapLabel);
|
$wrapLabel = str_replace($matches[0], '', $wrapLabel);
|
||||||
$wrapIcon = $matches[1];
|
$wrapIcon = $matches[1];
|
||||||
}
|
}
|
||||||
if(strpos($wrapLabel, '#') !== false && preg_match('/#([0-9a-fA-F]{3,})/', $wrapLabel, $matches)) {
|
if(strpos($wrapLabel, '#') !== false && preg_match('/(?<!&)#([0-9a-fA-F]{3,})/', $wrapLabel, $matches)) {
|
||||||
// background-color definition
|
// background-color definition
|
||||||
if(strlen($matches[1]) === 3 || strlen($matches[1]) === 6) {
|
if(strlen($matches[1]) === 3 || strlen($matches[1]) === 6) {
|
||||||
$wrapLabel = str_replace($matches[0], '', $wrapLabel);
|
$wrapLabel = str_replace($matches[0], '', $wrapLabel);
|
||||||
|
Reference in New Issue
Block a user