PDA

Zobacz pełną wersję : Jak usunąć "wiadomość" w templatce oxygen-free?



(Na)Leśnik
13-08-2011, 17:21
Witam.
Mam przegląd artykułów na stronie startowej http://www.marienwalde.pl (http://www.marienwalde.pl/)
Tylko przy templatce wymienionej w tytule pojawia mi się coś takiego jak "wiadomość".
Jak to usunąć?

wojsmol
14-08-2011, 00:05
Witam
Widzę, że używasz tego szablonu na Joomla! 1.7.0. Ostatnio miałem podobny problem podczas migracji strony z Joomla! 1.6.x na Joomla! 1.7.0. Przyczyną problemu jest sposób w jaki ten szablon w starszych wersjach sprawdza czy wystąpiły błędy. Do następnej swojej odpowiedzi wklej zawartość index.php swojego szablonu.
Pozdrawiam

(Na)Leśnik
14-08-2011, 07:39
Problem faktycznie pojawił się na Joomla 1.7, bo na 1.6 czegoś takiego nie było.
Poniżej index.php

<?php // no direct access
defined( '_JEXEC' ) or die( 'Restricted access' );
$showLeftColumn = (bool) $this->countModules('position-7');
$showRightColumn = (bool) $this->countModules('position-6');
$showRightColumn &= JRequest::getCmd('layout') != 'edit';

$margin = 30;
$outermargin = 0;
$logoText = $this->params->get("logoText","OXYGEN");
$slogan = $this->params->get("slogan","JOOMLA TEMPLATE FROM A4JOOMLA.COM");
$pageWidth = $this->params->get("pageWidth", "960");
$pageWidth = $pageWidth - $outermargin;
$rightColumnWidth = $this->params->get("rightColumnWidth", "190");
$leftColumnWidth = $this->params->get("leftColumnWidth", "190");
$logoWidth = $this->params->get("logoWidth", "400");
$removeBanner = $this->params->get("removeBanner", "No");

if($this->countModules('position-0')){
$searchWidth = 170;
} else {
$searchWidth = 0;
}
$headerrightWidth = $pageWidth + $outermargin - $logoWidth - 50;
$searchHeight = 33;
if ($showLeftColumn && $showRightColumn) {
$contentWidth = $pageWidth - $leftColumnWidth - $rightColumnWidth - 3*$margin;
} elseif (!$showLeftColumn && $showRightColumn) {
$contentWidth = $pageWidth - $rightColumnWidth - 2*$margin ;
} elseif ($showLeftColumn && !$showRightColumn) {
$contentWidth = $pageWidth - $leftColumnWidth - 2*$margin ;
} else {
$contentWidth = $pageWidth - $margin ;
}
JHTML::_('behavior.framework', true);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>" >

<head>
<link href='http://fonts.googleapis.com/css?family=Bentham' rel='stylesheet' type='text/css' />
<jdoc:include type="head" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/system.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/general.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/css/template.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/css/grey.css" type="text/css" />
<!--[if IE 6]>
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/css/ie6.css" type="text/css" />
<style type="text/css">
img, div, a, input { behavior: url(<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/iepngfix.htc) }
#search input.inputbox { behavior:none;}
</style>
<script src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/js/iepngfix_tilebg.js" type="text/javascript"></script>
<![endif]-->
<!--[if lte IE 7]>
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/css/ie67.css" type="text/css" />
<![endif]-->
<!--[if lte IE 8]>
<style type="text/css">
#search input.inputbox { behavior: url(<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/js/PIE.php) }
</style>
<![endif]-->
<style type="text/css">
#logo {
width:<?php echo $logoWidth; ?>px;
}
#headerright {
width:<?php echo $headerrightWidth; ?>px;
<?php if($this->countModules('banner') || $removeBanner == "Yes") : ?>
background: none;
<?php endif; ?>
}
#search {
width:<?php echo $searchWidth; ?>px;
height:<?php echo $searchHeight; ?>px;
}
</style>
</head>
<body>



<div id="allwrap" class="gainlayout" style="width:<?php echo $pageWidth + $outermargin; ?>px;">

<div id="headerwrap" class="gainlayout">
<div id="header" class="gainlayout">
<div id="logo" class="gainlayout">
<h2><a href="<?php echo JURI::base(); ?>" title="<?php echo htmlspecialchars($logoText); ?>"><?php echo htmlspecialchars($logoText); ?></a></h2>
<h3><?php echo htmlspecialchars($slogan); ?></h3>
</div>
<div id="headerright" class="gainlayout">
<?php if($this->countModules('banner')) : ?>
<div id="banner">
<jdoc:include type="modules" name="banner" style="xhtml" />
</div>
<?php endif; ?>
<div class="clr"></div>
</div>
<div class="clr"></div>
</div>
<div class="clr"></div>
</div>

<div id="topmenuwrap" class="gainlayout">
<?php if($this->countModules('position-1')) : ?>
<div id="topmenu" class="gainlayout">
<jdoc:include type="modules" name="position-1" style="xhtml" />
<div class="clr"></div>
</div>
<?php endif; ?>
<?php if($this->countModules('position-0')) : ?>
<div id="search" class="gainlayout">
<jdoc:include type="modules" name="position-0" style="xhtml" />
<div class="clr"></div>
</div>
<?php endif; ?>
<div class="clr"></div>
</div>

<div id="wrap" class="gainlayout">

<?php if($this->countModules('position-2')) : ?>
<div id="pathway" class="gainlayout">
<jdoc:include type="modules" name="position-2" />
<div class="clr"></div>
</div>
<?php endif; ?>
<div id="cbody" class="gainlayout">
<?php if($showLeftColumn) : ?>
<div id="sidebar" style="width:<?php echo $leftColumnWidth; ?>px;">
<jdoc:include type="modules" name="position-7" style="xhtml" />
</div>
<?php endif; ?>
<div id="content60" style="width:<?php echo $contentWidth; ?>px;">

<?php if ($this->getBuffer('message')) : ?>
<div class="error">
<h2>
<?php echo JText::_('Message'); ?>
</h2>
<jdoc:include type="message" />
</div>
<?php endif; ?>
<div id="content" class="gainlayout">
<jdoc:include type="component" />
</div>
</div>
<?php if($showRightColumn) : ?>
<div id="sidebar-2" style="width:<?php echo $rightColumnWidth; ?>px;">
<jdoc:include type="modules" name="position-6" style="xhtml" />
</div>
<?php endif; ?>
<div class="clr"></div>
</div>

<!--end of wrap-->
</div>

<!--end of allwrap-->
</div>
<div id="footerwrap" class="gainlayout" style="width:<?php echo $pageWidth + $outermargin; ?>px;">
<div id="footer" class="gainlayout">
<?php if($this->countModules('position-14')) : ?>
<jdoc:include type="modules" name="position-14" style="xhtml" />
<?php endif; ?>
</div>
<div id="a4j"><a href="http://a4joomla.com/"><?php echo JText::_('TPL_A4JOOMLA-OXYGEN-FREE_FOOTER_LINK_TEXT');?></a></div>
</div>


</body>
</html>

wojsmol
14-08-2011, 15:57
Witam
zamień
<?php if ($this->getBuffer('message')) : ?>na
<?php if (count(JFactory::getApplication()->getMessageQueue())) : ?>Pozdrawiam

(Na)Leśnik
15-08-2011, 10:57
Działa.
Bardzo dziękuję.