Commit a4d9aab6 authored by Matthias Larisch's avatar Matthias Larisch

Remove unused templates

parent 618ec46a
Pipeline #22180905 failed with stages
in 8 minutes and 18 seconds
......@@ -1065,7 +1065,6 @@ Verantwortlich für den Inhalt nach § 55 Abs. 2 RStV:<br />
$this->js_func .= $nfunc;
}
// $js is echoed in tpl/default.php
public function addJs($njs)
{
$this->js .= $njs;
......@@ -1405,7 +1404,7 @@ Verantwortlich für den Inhalt nach § 55 Abs. 2 RStV:<br />
{
showLoader();
$.ajax({
dataType:"json",
url:"xhr.php?f=update_' . $table . '&" + $("#' . $id . ' form").serialize(),
success : function(data){
......@@ -1422,7 +1421,7 @@ Verantwortlich für den Inhalt nach § 55 Abs. 2 RStV:<br />
});
}
}
});
});
');
}
......@@ -1772,11 +1771,6 @@ Verantwortlich für den Inhalt nach § 55 Abs. 2 RStV:<br />
file_get_contents(SOCK_URL . '?' . $query);
}
public function getTemplate($tpl)
{
include 'tpl/' . $tpl . '.php';
}
// https://stackoverflow.com/a/834355
public function endsWith($haystack, $needle)
{
......
<?php
use Foodsharing\DI;
use Foodsharing\Lib\Func;
$func = DI::$shared->get(Func::class);
$content_left = $func->getContent(CNT_LEFT);
$content_right = $func->getContent(CNT_RIGHT);
$content_top = $func->getContent(CNT_TOP);
$content_bottom = $func->getContent(CNT_BOTTOM);
$content_main = $func->getContent(CNT_MAIN);
$content_overtop = $func->getContent(CNT_OVERTOP);
$mainwidth = 24;
if (!empty($content_left)) {
$mainwidth -= $content_left_width;
$content_left = '
<div class="pure-u-1 pure-u-md-' . $content_left_width . '-24" id="left">
<div class="inside">
' . $content_left . '
</div>
</div>';
}
if (!empty($content_right)) {
$mainwidth -= $content_right_width;
$content_right = '
<div class="pure-u-1 pure-u-md-' . $content_right_width . '-24" id="right">
<div class="inside">
' . $content_right . '
</div>
</div>';
}
if (!empty($content_top)) {
//$content_top = '';
$content_top = '
<div class="pure-g">
<div id="content_top" class="pure-u-1">
<div class="inside">
' . $content_top . '
</div>
</div>
</div>';
}
if (!empty($content_bottom)) {
$content_bottom = '
<div class="pure-g">
<div class="pure-u-1" id="content_bottom">
<div class="inside">
' . $content_bottom . '
</div>
</div>
</div>';
}
if (!empty($content_main)) {
$content_main = '
<div class="pure-u-1 pure-u-md-' . $mainwidth . '-24">
<div class="inside">
' . $content_main . '
</div>
</div>';
}
if (!empty($content_left) && !empty($content_right)) {
//addStyle('div#content{width:513px;}');
}
?><!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="favicon" href="/favicon.ico" type="image/x-icon" />
<?php echo $func->getHead(); ?>
<style type="text/css"><?php echo str_replace(array("\r", "\n"), '', $func->getAddCss()); ?></style>
<script type="text/javascript">
var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-43313114-1']); _gaq.push(['_setDomainName', '<?php echo $_SERVER['HTTP_HOST']; ?>']); _gaq.push(['_trackPageview']); (function() {var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })();
</script>
<script type="text/javascript"><?php
echo $func->getJsFunc(); ?> $(document).ready(function(){<?php echo $func->getJs(); ?>});</script>
</head>
<body<?php echo $g_body_class; ?>>
<div id="top">
<div class="inner">
<div class="pure-g">
<div class="pure-u-1">
<div id="layout_logo"><a href="<?php echo $logolink; ?>" title="foodsharing home">food<span>sharing</span></a></div>
<?php echo $msgbar; ?>
<?php echo $menu['mobile']; ?>
<div class="menu">
<?php echo $menu['default']; ?>
</div>
<div style="clear:both;"></div>
</div>
</div>
</div>
<?php if (!empty($g_broadcast_message)) {
?>
<div class="inner inside msg-inside info"><?php echo $g_broadcast_message; ?></div>
<?php
}?>
</div>
<?php echo $content_overtop; ?>
<div id="main"<?php if ($func->isMob()) {
?> class="mobile"<?php
} ?>>
<?php echo $func->getBread(); ?>
<?php echo $content_top; ?>
<div class="pure-g mainpure">
<?php
if ($func->isMob()) {
echo $content_main;
echo $content_right;
echo $content_left;
} else {
echo $content_left;
echo $content_main;
echo $content_right;
}
?>
</div>
<?php echo $content_bottom; ?>
</div>
<?php $func->getTemplate('footer'); ?>
<noscript>
<div id="nojs">Ohne JavaScript l&auml;uft hier leider nichts.</div>
</noscript>
<?php $func->printHidden(); ?>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-error" style="display:none;"></div>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-info" style="display:none;"></div>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-success" style="display:none;"></div>
</body>
</html>
<footer>
<div class="wrapper">
<div class="pure-g">
<div class="pure-u-1 pure-u-md-4-24">
<div class="inside">
<ul class="linklist">
<li><a class="corner-all" href="/team">Team</a></li>
<li><a class="corner-all" href="/impressum">Impressum</a></li>
<li><a class="corner-all" href="/ratgeber">Ratgeber</a></li>
<li><a class="corner-all" href="/fuer-unternehmen">Unternehmen</a></li>
</ul>
</div>
</div>
<div class="pure-u-1 pure-u-md-4-24">
<div class="inside">
<ul class="linklist">
<li><a class="corner-all" href="/partner">Partner</a></li>
<li><a class="corner-all" href="/statistik">Statistik</a></li>
<li><a class="corner-all" href="/faq">F.A.Q.</a></li>
<li><a class="corner-all" href="/unterstuetzung">Spenden</a></li>
</ul>
</div>
</div>
<div class="pure-u-1 pure-u-md-4-24" style="padding-top:30px;width:126px;margin:0 auto;">
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="CLPZCSCKGNXE4">
<input type="image" src="https://www.paypalobjects.com/de_DE/DE/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="Jetzt einfach, schnell und sicher online spenden – mit PayPal.">
<img alt="" border="0" src="https://www.paypalobjects.com/de_DE/i/scr/pixel.gif" width="1" height="1">
</form>
</div>
<div class="pure-u-1 pure-u-md-12-24">
<div class="inside">
<?php
if (strpos($_SERVER['HTTP_HOST'], 'foodsharing.at') !== false) {
?>
<a class="corner-all" href="http://www.bmlfuw.gv.at/" target="_blank"><img src="/img/mfelo.png" alt="Lebensministerium" /></a>
<a class="corner-all" href="http://www.wienertafel.at/" target="_blank"><img src="/img/wien_tafel.png" alt="Wiener Tafel" /></a>
<a class="corner-all" href="http://www.denns-biomarkt.at/" target="_blank"><img src="/img/denns_logo_100.png" alt="Denn's Biomarkt" /></a>
<?php
}
?>
<h6>Vielen Dank an unseren Öko-Hoster</h6>
<a class="corner-all imglink" href="https://www.manitu.de/" target="_blank"><img src="/img/manitu_logo.png" alt="Manitu" /></a>
</div>
</div>
</div>
<div class="inside" style="margin-top:1em;">
<?php if (defined('SRC_REVISION')) {
echo '<a href="https://gitlab.com/foodsharing-dev/foodsharing/tree/' . SRC_REVISION . '">';
echo 'Version: ' . SRC_REVISION . '</a>';
} else {
echo '<a href="https://gitlab.com/foodsharing-dev/">';
echo 'Hello World! This website is under active development!</a>';
}
?>
</div>
</div>
</footer>
<?php
use Foodsharing\DI;
use Foodsharing\Lib\Func;
$func = DI::$shared->get(Func::class);
header('Pragma-directive: no-cache');
header('Cache-directive: no-cache');
header('Cache-control: no-cache');
header('Pragma: no-cache');
header('Expires: 0');
?><!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>foodsharing | Restlos Glücklich!</title>
<link rel="favicon" href="favicon.ico" type="image/x-icon" />
<?php echo $func->getHead(); ?>
<link rel="stylesheet" href="/js/markercluster/dist/MarkerCluster.css" />
<link rel="stylesheet" href="/js/markercluster/dist/MarkerCluster.Default.css" />
<style type="text/css"><?php echo $func->getAddCss(); ?></style>
<script type="text/javascript">
var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-43313114-1']); _gaq.push(['_setDomainName', '<?php echo $_SERVER['HTTP_HOST']; ?>']); _gaq.push(['_trackPageview']); (function() {var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })();
</script>
<script type="text/javascript">
<?php echo $func->getJsFunc(); ?>
$(document).ready(function(){
<?php echo $func->getJs(); ?>
});
</script>
</head>
<body<?php echo $g_body_class; ?>>
<div id="top">
<div class="inner">
<div class="pure-g">
<div class="pure-u-1">
<div id="layout_logo"><a href="/" title="foodsharing home"><span>food</span>sharing</a></div>
<?php echo $msgbar; ?>
<?php echo $menu['mobile']; ?>
<div class="menu">
<?php echo $menu['default']; ?>
</div>
<div style="clear:both;"></div>
</div>
</div>
</div>
</div>
<?php echo $func->getContent(CNT_MAIN); ?>
<?php echo $func->getContent(CNT_TOP); ?>
<noscript>
<div id="nojs">Ohne JavaScript l&auml;uft hier leider nichts.</div>
</noscript>
<?php $func->printHidden(); ?>
<div class="pulse-msg ui-shadow" id="pulse-error" style="display:none;"></div>
<div class="pulse-msg ui-shadow" id="pulse-info" style="display:none;"></div>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-success" style="display:none;"></div>
</body>
</html>
<?php
use Foodsharing\DI;
use Foodsharing\Lib\Func;
$func = DI::$shared->get(Func::class);
$content_left = $func->getContent(CNT_LEFT);
$content_right = $func->getContent(CNT_RIGHT);
$content_top = $func->getContent(CNT_TOP);
$content_bottom = $func->getContent(CNT_BOTTOM);
$content_main = $func->getContent(CNT_MAIN);
$content_overtop = $func->getContent(CNT_OVERTOP);
$mainwidth = 24;
if (!empty($content_left)) {
$mainwidth -= 5;
$content_left = '
<div class="pure-u-1 pure-u-md-5-24" id="left">
<div class="inside">
' . $content_left . '
</div>
</div>';
}
if (!empty($content_right)) {
$mainwidth -= 8;
$content_right = '
<div class="pure-u-1 pure-u-md-8-24" id="right">
<div class="inside">
' . $content_right . '
</div>
</div>';
}
if (!empty($content_bottom)) {
$content_bottom = '
<div class="pure-g">
<div class="pure-u-1" id="content_bottom">
<div class="inside">
' . $content_bottom . '
</div>
</div>
</div>';
}
if (!empty($content_main)) {
$content_main = '
<div class="pure-u-1 pure-u-md-' . $mainwidth . '-24">
<div class="inside">
' . $content_top . '
' . $content_main . '
</div>
</div>';
}
?><!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="favicon" href="favicon.ico" type="image/x-icon" />
<?php echo $func->getHead(); ?>
<style type="text/css"><?php echo $func->getAddCss(); ?></style>
<script type="text/javascript">
var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-43313114-1']); _gaq.push(['_setDomainName', 'lebensmittelretten.de']); _gaq.push(['_trackPageview']); (function() {var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })();
</script>
<script type="text/javascript">
<?php echo $func->getJsFunc(); ?>
$(document).ready(function(){
<?php echo $func->getJs(); ?>
});
</script>
</head>
<body<?php echo $g_body_class; ?>>
<div id="top">
<div class="inner">
<div class="pure-g">
<div class="pure-u-1">
<div id="layout_logo"><a href="<?php echo $logolink; ?>" title="foodsharing home"><span>food</span>sharing</a></div>
<?php echo $msgbar; ?>
<?php echo $menu['mobile']; ?>
<div class="menu">
<?php echo $menu['default']; ?>
</div>
<div style="clear:both;"></div>
</div>
</div>
</div>
</div>
<?php echo $content_overtop; ?>
<div id="main"<?php if ($func->isMob()) {
?> class="mobile"<?php
} ?>>
<?php echo $func->getBread(); ?>
<div class="pure-g mainpure">
<?php
if ($func->isMob()) {
echo $content_main;
echo $content_right;
echo $content_left;
} else {
echo $content_left;
echo $content_main;
echo $content_right;
}
?>
</div>
<?php echo $content_bottom; ?>
</div>
<noscript>
<div id="nojs">Ohne JavaScript l&auml;uft hier leider nichts.</div>
</noscript>
<?php $func->printHidden(); ?>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-error" style="display:none;"></div>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-info" style="display:none;"></div>
<div class="pulse-msg ui-shadow ui-corner-all" id="pulse-success" style="display:none;"></div>
</body>
</html>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment