1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-16 03:24:20 +02:00

Export of plugin prefs complete.

This commit is contained in:
Cameron
2016-12-24 12:41:06 -08:00
parent cbc6beb789
commit 5f0419cac4
2 changed files with 36 additions and 5 deletions

View File

@@ -872,7 +872,7 @@ class xmlClass
* @param boolean $debug [optional]
* @return string text / file for download
*/
public function e107Export($xmlprefs, $tables, $mode = false)
public function e107Export($xmlprefs, $tables, $plugPrefs, $mode = false)
{
// error_reporting(0);
$e107info = array();
@@ -921,6 +921,32 @@ class xmlClass
$text .= "\t</prefs>\n";
}
if(!empty($plugPrefs))
{
$text .= "\t<pluginPrefs>\n";
foreach($plugPrefs as $plug)
{
$prefs = e107::getPlugConfig($plug)->getPref();
foreach($prefs as $key=>$val)
{
if(isset($val))
{
$text .= "\t\t<".$plug." name=\"".$key."\">".$this->e107ExportValue($val)."</".$plug.">\n";
}
}
}
$text .= "\t</pluginPrefs>\n";
}
if(varset($tables))
{
$text .= "\t<database>\n";
@@ -967,7 +993,7 @@ class xmlClass
if($mode === 'debug')
{
echo "<pre>".htmlentities($text)."</pre>";
return TRUE;
return null;
}
else
{