- if (is_array($l) AND !$l[0]) {
- foreach ($l as $k => $p) {
- if ($p AND $p[0]->type == 'texte' AND !strpos($p[0]->texte,'=')) {
- $p[0]->texte = trim($p[0]->texte);
- }
- }
- foreach ($l as $k => $p) {
- if (!$p OR $p[0]->type != 'texte' OR
- !preg_match('/^fond\s*=\s*(.*)$/',$p[0]->texte, $r))
- continue;
-
- if ($r[1])
- $p[0]->texte = $r[1];
- else unset($p[0]);
- $champ->texte = $p;
- unset($champ->param[0][$k]);
- if (count($champ->param[0]) ==1)
- array_shift($champ->param);
- return;
- }
+ if (is_array($l) and !$l[0]) {
+ foreach ($l as $k => $p) {
+ if ($p and $p[0]->type == 'texte' and !strpos($p[0]->texte, '=')) {
+ $p[0]->texte = trim($p[0]->texte);
+ }
+ }
+ foreach ($l as $k => $p) {
+ if (!$p or $p[0]->type != 'texte' or
+ !preg_match('/^fond\s*=\s*(.*)$/', $p[0]->texte, $r)
+ ) {
+ continue;
+ }
+
+ if ($r[1]) {
+ $p[0]->texte = $r[1];
+ } else {
+ unset($p[0]);
+ }
+ $champ->texte = $p;
+ unset($champ->param[0][$k]);
+ if (count($champ->param[0]) == 1) {
+ array_shift($champ->param);
+ }
+
+ return;
+ }