-
AuthorPosts
-
localconnectionsmagazine Friend
localconnectionsmagazine
- Join date:
- June 2009
- Posts:
- 36
- Downloads:
- 0
- Uploads:
- 5
- Thanks:
- 8
November 13, 2012 at 7:07 am #182192Looking to insert a top banner tried different positions (please see the attached image for position) but can’t find top header is this possible
thanks for looking
localconnections
pavit Moderatorpavit
- Join date:
- September 2007
- Posts:
- 15749
- Downloads:
- 199
- Uploads:
- 2274
- Thanks:
- 417
- Thanked:
- 4028 times in 3778 posts
November 13, 2012 at 7:29 am #472740Hi
When you choose the position in module manager manually write top-panel inside it
Or you need to insert a new position in header
localconnectionsmagazine Friendlocalconnectionsmagazine
- Join date:
- June 2009
- Posts:
- 36
- Downloads:
- 0
- Uploads:
- 5
- Thanks:
- 8
November 13, 2012 at 7:55 am #472743hi pavit,
thanks for the reply i tried it but top-panel is above the position i need banner inpavit Moderatorpavit
- Join date:
- September 2007
- Posts:
- 15749
- Downloads:
- 199
- Uploads:
- 2274
- Thanks:
- 417
- Thanked:
- 4028 times in 3778 posts
November 13, 2012 at 8:27 am #472749Ok
Then you can create a specific position for your banner inside the header
Goto this file pluginssystemjat3jat3base-themesdefaultblocksheader.php now you have
defined('_JEXEC') or die;
?>
<?php
$app = JFactory::getApplication();
$siteName = $app->getCfg('sitename');
if ($this->getParam('logoType', 'image')=='image'): ?>
<h1 class="logo">
<a href="<?php JURI::base(true) ?>" title="<?php echo $siteName; ?>"><span><?php echo $siteName; ?></span></a>
</h1>
<?php else:
$logoText = (trim($this->getParam('logoText'))=='') ? $siteName : JText::_(trim($this->getParam('logoText')));
$sloganText = JText::_(trim($this->getParam('sloganText'))); ?>
<div class="logo-text">
<h1><a href="<?php JURI::base(true) ?>" title="<?php echo $siteName; ?>"><span><?php echo $logoText; ?></span></a></h1>
<p class="site-slogan"><?php echo $sloganText;?></p>
</div>
<?php endif; ?><?php if($this->countModules('search')) : ?>
<div id="ja-search">
<jdoc:include type="modules" name="search" />
</div>
<?php endif; ?>Add this php code
<?php if($this->countModules('bannerheader')) : ?>
<div id="ja-bannerheader">
<jdoc:include type="modules" name="bannerheader" />
</div>
<?php endif; ?>So the new header.php file will be
defined('_JEXEC') or die;
?>
<?php
$app = JFactory::getApplication();
$siteName = $app->getCfg('sitename');
if ($this->getParam('logoType', 'image')=='image'): ?>
<h1 class="logo">
<a href="<?php JURI::base(true) ?>" title="<?php echo $siteName; ?>"><span><?php echo $siteName; ?></span></a>
</h1>
<?php else:
$logoText = (trim($this->getParam('logoText'))=='') ? $siteName : JText::_(trim($this->getParam('logoText')));
$sloganText = JText::_(trim($this->getParam('sloganText'))); ?>
<div class="logo-text">
<h1><a href="<?php JURI::base(true) ?>" title="<?php echo $siteName; ?>"><span><?php echo $logoText; ?></span></a></h1>
<p class="site-slogan"><?php echo $sloganText;?></p>
</div>
<?php endif; ?>
<?php if($this->countModules('bannerheader')) : ?>
<div id="ja-bannerheader">
<jdoc:include type="modules" name="bannerheader" />
</div>
<?php endif; ?>
<?php if($this->countModules('search')) : ?>
<div id="ja-search">
<jdoc:include type="modules" name="search" />
</div>
<?php endif; ?>Now goto this file templatesja_universitytemplateDetails.xml and add the new position
<position>top-panel</position>
<position>bannerheader</position>Now goto templatesja_universitycsstemplate.css and at the end of file add the css style for your new position
#ja-bannerheader {
margin-top: 20px;
}Remember that based on your custom-html module you will need to find the right positioning CSS settings also take first a backup that you will modify
Regards
1 user says Thank You to pavit for this useful post
localconnectionsmagazine Friendlocalconnectionsmagazine
- Join date:
- June 2009
- Posts:
- 36
- Downloads:
- 0
- Uploads:
- 5
- Thanks:
- 8
November 13, 2012 at 9:36 am #472758hi pavit,
This is the default banner position on most templates. because it is not displaying properly or maybe i am doing something wrong. also it is only to add a slogan in where the banner will be to compliment the logo but i was going to use the banner module to display the slogan that will change depending on the language. Has anyone else put a banner in the position to the right of the logo. I can’t see this should require custom coding but I appreciate the code i just would like confirmation before i alter the template.thanks
andrew
localconnectionsmagazine Friendlocalconnectionsmagazine
- Join date:
- June 2009
- Posts:
- 36
- Downloads:
- 0
- Uploads:
- 5
- Thanks:
- 8
November 13, 2012 at 6:17 pm #472812hi pavit, i didnĀ“t understand why banner position was listed but not used in the template i have used your code andit works perfectly.
many thanks
localconnections
AuthorPostsViewing 6 posts - 1 through 6 (of 6 total)This topic contains 6 replies, has 2 voices, and was last updated by localconnectionsmagazine 12 years, 1 month ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Banner position
Viewing 6 posts - 1 through 6 (of 6 total)