|
|
@@ -591,7 +591,7 @@ EOF';
|
|
|
else $child->appendChild($dom->createCDATASection($data));
|
|
|
} else $parent->appendChild($child);
|
|
|
}
|
|
|
- if ($child->hasChildNodes()) $parent->appendChild($child);
|
|
|
+ if ($child->hasChildNodes() || $child->hasAttributes()) $parent->appendChild($child);
|
|
|
};
|
|
|
|
|
|
if (!is_array($array)) throw new Exception("First argument need to be an array");
|