Vergleich admin/modules/style/themes.php - 1.8.16 - 1.8.18

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 584Zeile 584
		$inherited_load[] = $mybb->input['tid'];
$inherited_load = array_unique($inherited_load);


		$inherited_load[] = $mybb->input['tid'];
$inherited_load = array_unique($inherited_load);


		$inherited_themes = array();

		$inherited_themes = $theme_stylesheets = array();

		if(count($inherited_load) > 0)
{
$query = $db->simple_select("themes", "tid, name", "tid IN (".implode(",", $inherited_load).")");

		if(count($inherited_load) > 0)
{
$query = $db->simple_select("themes", "tid, name", "tid IN (".implode(",", $inherited_load).")");

Zeile 592Zeile 592
			{
$inherited_themes[$inherited_theme['tid']] = $inherited_theme['name'];
}

			{
$inherited_themes[$inherited_theme['tid']] = $inherited_theme['name'];
}

		}

$theme_stylesheets = array();

 




		if(count($inherited_load) > 0)
{

 
			$query = $db->simple_select("themestylesheets", "*", "tid IN (".implode(",", $inherited_load).")", array('order_by' => 'tid', 'order_dir' => 'desc'));
while($theme_stylesheet = $db->fetch_array($query))
{

			$query = $db->simple_select("themestylesheets", "*", "tid IN (".implode(",", $inherited_load).")", array('order_by' => 'tid', 'order_dir' => 'desc'));
while($theme_stylesheet = $db->fetch_array($query))
{

Zeile 606Zeile 601
					$theme_stylesheets[$theme_stylesheet['cachefile']] = $theme_stylesheet;
$theme_stylesheets[$theme_stylesheet['sid']] = $theme_stylesheet['cachefile'];
}

					$theme_stylesheets[$theme_stylesheet['cachefile']] = $theme_stylesheet;
$theme_stylesheets[$theme_stylesheet['sid']] = $theme_stylesheet['cachefile'];
}

			}
}

			}
}


$xml .= "\t<stylesheets>\r\n";
foreach($stylesheets as $filename => $style)


$xml .= "\t<stylesheets>\r\n";
foreach($stylesheets as $filename => $style)

Zeile 647Zeile 642
			$filename = $theme_stylesheets[$filename]['name'];

$xml .= "\t\t<stylesheet name=\"{$filename}\" {$attachedto}version=\"{$mybb->version_code}\"><![CDATA[{$stylesheet}]]>\r\n\t\t</stylesheet>\r\n";

			$filename = $theme_stylesheets[$filename]['name'];

$xml .= "\t\t<stylesheet name=\"{$filename}\" {$attachedto}version=\"{$mybb->version_code}\"><![CDATA[{$stylesheet}]]>\r\n\t\t</stylesheet>\r\n";


}


}

		$xml .= "\t</stylesheets>\r\n";

if($mybb->input['include_templates'] != 0)

		$xml .= "\t</stylesheets>\r\n";

if($mybb->input['include_templates'] != 0)

Zeile 677Zeile 672
		header("Expires: 0");
echo $xml;
exit;

		header("Expires: 0");
echo $xml;
exit;

	}


	}


	$page->add_breadcrumb_item(htmlspecialchars_uni($theme['name']), "index.php?module=style-themes&amp;action=edit&amp;tid={$mybb->input['tid']}");

$page->add_breadcrumb_item($lang->export_theme, "index.php?module=style-themes&amp;action=export");

	$page->add_breadcrumb_item(htmlspecialchars_uni($theme['name']), "index.php?module=style-themes&amp;action=edit&amp;tid={$mybb->input['tid']}");

$page->add_breadcrumb_item($lang->export_theme, "index.php?module=style-themes&amp;action=export");

Zeile 706Zeile 701
		'link' => "index.php?module=style-themes&amp;action=duplicate&amp;tid={$mybb->input['tid']}",
'description' => $lang->duplicate_theme_desc
);

		'link' => "index.php?module=style-themes&amp;action=duplicate&amp;tid={$mybb->input['tid']}",
'description' => $lang->duplicate_theme_desc
);





	$page->output_nav_tabs($sub_tabs, 'export_theme');

if($errors)

	$page->output_nav_tabs($sub_tabs, 'export_theme');

if($errors)

Zeile 745Zeile 740
	}

$plugins->run_hooks("admin_style_themes_duplicate");

	}

$plugins->run_hooks("admin_style_themes_duplicate");





	if($mybb->request_method == "post")
{
if($mybb->input['name'] == "")

	if($mybb->request_method == "post")
{
if($mybb->input['name'] == "")

		{

		{

			$errors[] = $lang->error_missing_name;
}
else
{
$query = $db->simple_select("themes", "COUNT(tid) as numthemes", "name = '".$db->escape_string($mybb->get_input('name'))."'");

			$errors[] = $lang->error_missing_name;
}
else
{
$query = $db->simple_select("themes", "COUNT(tid) as numthemes", "name = '".$db->escape_string($mybb->get_input('name'))."'");

			$numthemes = $db->fetch_field($query, 'numthemes');

if($numthemes)
{
$errors[] = $lang->error_theme_already_exists;
}

			$numthemes = $db->fetch_field($query, 'numthemes');

if($numthemes)
{
$errors[] = $lang->error_theme_already_exists;
}

		}

if(!$errors)

		}

if(!$errors)

Zeile 771Zeile 766
			if($mybb->input['duplicate_templates'])
{
$nsid = $db->insert_query("templatesets", array('title' => $db->escape_string($mybb->input['name'])." Templates"));

			if($mybb->input['duplicate_templates'])
{
$nsid = $db->insert_query("templatesets", array('title' => $db->escape_string($mybb->input['name'])." Templates"));





				// Copy all old Templates to our new templateset
$query = $db->simple_select("templates", "*", "sid='{$sid}'");
while($template = $db->fetch_array($query))

				// Copy all old Templates to our new templateset
$query = $db->simple_select("templates", "*", "sid='{$sid}'");
while($template = $db->fetch_array($query))

Zeile 791Zeile 786
					}

$db->insert_query("templates", $insert);

					}

$db->insert_query("templates", $insert);

				}

				}


// We need to change the templateset so we need to work out the others properties too
foreach($properties as $property => $value)


// We need to change the templateset so we need to work out the others properties too
foreach($properties as $property => $value)

Zeile 832Zeile 827
	$page->add_breadcrumb_item($lang->duplicate_theme, "index.php?module=style-themes&amp;action=duplicate&amp;tid={$theme['tid']}");

$page->output_header("{$lang->themes} - {$lang->duplicate_theme}");

	$page->add_breadcrumb_item($lang->duplicate_theme, "index.php?module=style-themes&amp;action=duplicate&amp;tid={$theme['tid']}");

$page->output_header("{$lang->themes} - {$lang->duplicate_theme}");





	$sub_tabs['edit_stylesheets'] = array(
'title' => $lang->edit_stylesheets,
'link' => "index.php?module=style-themes&amp;action=edit&amp;tid={$mybb->input['tid']}",

	$sub_tabs['edit_stylesheets'] = array(
'title' => $lang->edit_stylesheets,
'link' => "index.php?module=style-themes&amp;action=edit&amp;tid={$mybb->input['tid']}",

	);


	);


	$sub_tabs['add_stylesheet'] = array(
'title' => $lang->add_stylesheet,
'link' => "index.php?module=style-themes&amp;action=add_stylesheet&amp;tid={$mybb->input['tid']}",

	$sub_tabs['add_stylesheet'] = array(
'title' => $lang->add_stylesheet,
'link' => "index.php?module=style-themes&amp;action=add_stylesheet&amp;tid={$mybb->input['tid']}",

	);


	);


	$sub_tabs['export_theme'] = array(
'title' => $lang->export_theme,
'link' => "index.php?module=style-themes&amp;action=export&amp;tid={$mybb->input['tid']}",

	$sub_tabs['export_theme'] = array(
'title' => $lang->export_theme,
'link' => "index.php?module=style-themes&amp;action=export&amp;tid={$mybb->input['tid']}",

Zeile 1245Zeile 1240
	$inherited_load[] = $mybb->input['tid'];
$inherited_load = array_unique($inherited_load);


	$inherited_load[] = $mybb->input['tid'];
$inherited_load = array_unique($inherited_load);


	$inherited_themes = array();

	$inherited_themes = $theme_stylesheets = array();

	if(count($inherited_load) > 0)
{
$query = $db->simple_select("themes", "tid, name", "tid IN (".implode(",", $inherited_load).")");

	if(count($inherited_load) > 0)
{
$query = $db->simple_select("themes", "tid, name", "tid IN (".implode(",", $inherited_load).")");

Zeile 1253Zeile 1248
		{
$inherited_themes[$inherited_theme['tid']] = $inherited_theme['name'];
}

		{
$inherited_themes[$inherited_theme['tid']] = $inherited_theme['name'];
}

	}

$theme_stylesheets = array();

 




	if(count($inherited_load) > 0)
{

 
		$query = $db->simple_select("themestylesheets", "*", "", array('order_by' => 'sid DESC, tid', 'order_dir' => 'desc'));
while($theme_stylesheet = $db->fetch_array($query))
{

		$query = $db->simple_select("themestylesheets", "*", "", array('order_by' => 'sid DESC, tid', 'order_dir' => 'desc'));
while($theme_stylesheet = $db->fetch_array($query))
{