contao/test — Issue #2883: Hook in compileDefinition und createDefinition und 
Author: felixpfeiffer
Created: 2011-11-29 10:29:49+00:00
State: open
Labels: backend, Feature

Hallo,

um zusätzliche Felder im Style-Editor zu verwenden (um z.B. CSS3 Eigenschaften bereit zu stellen) würde ich gerne zwei neue Hooks in der StyleSheet.php sehen:

Zeile 530:

```
// Custom Styles
if (isset($GLOBALS['TL_HOOKS']['customStyle']) && is_array($GLOBALS['TL_HOOKS']['customStyle']))
{
foreach ($GLOBALS['TL_HOOKS']['customStyle'] as $callback)
{
$this->import($callback[0]);
$return .= $this->$callback[0]->$callback[1]($row);
}

}
```

Zeile 1322:

```
default:
// Custom Styles
if (isset($GLOBALS['TL_HOOKS']['createStyleDefinition']) && is_array($GLOBALS['TL_HOOKS']['createStyleDefinition']))
{
foreach ($GLOBALS['TL_HOOKS']['createStyleDefinition'] as $callback)
{
$this->import($callback[0]);
$arrStyle = $this->$callback[0]->$callback[1]($strDefinition,$arrSet);

if($arrStyle)
{
$arrSet = array_merge($arrSet,$arrStyle);
continue 3;
}
}

}
$arrSet['own'][] = $strDefinition;
break;
```

Ich habe mal eine bearbeitete Version (Basis Contao 2.9.2) angehängt.

Gruß, Felix

[Download the attachments](http://www.contao.org/tl_files/tickets/2883.zip "Download the attachments of this ticket")

--- _Originally created on February 19th, 2011, at 11:54pm (ID 2883)_