-
AuthorPosts
-
hrasno Friend
hrasno
- Join date:
- April 2008
- Posts:
- 38
- Downloads:
- 7
- Uploads:
- 6
- Thanks:
- 11
- Thanked:
- 2 times in 2 posts
April 19, 2015 at 9:44 am #205648I would like to add a new block with two positions (left-size9 and right-size3) but after reading documentation and looking at default blocks I’m confused what code to use?
I’m trued this a can see it in layout but it doesn’t work when I assign module to a left position.
<?php
defined('_JEXEC') or die;
?><div id="row">
<?php if ($this->countModules('custom')) : ?>
<!-- left -->
<div class="col-xs-12 col-sm-9 <?php $this->_c('left') ?>">
<jdoc:include type="modules" name="<?php $this->_p('left') ?>" style="raw" />
</div>
<!-- //left -->
<!-- right -->
<div class="col-xs-12 col-sm-3 <?php $this->_c('right') ?>">
<jdoc:include type="modules" name="<?php $this->_p('right') ?>" style="raw" />
</div>
<!-- //right -->
<?php endif ?>
</div>Basicaly I need custom block with two possitions.
pavit Moderatorpavit
- Join date:
- September 2007
- Posts:
- 15749
- Downloads:
- 199
- Uploads:
- 2274
- Thanks:
- 417
- Thanked:
- 4028 times in 3778 posts
April 19, 2015 at 10:20 am #567498Hi
You can duplicate spotlight php file and name it spotlight-3 then load it through default.php file
1) templatest3_blanktplsdefault.php
<head>
<jdoc:include type="head" />
<?php $this->loadBlock ('head') ?>
</head><body>
<?php $this->loadBlock ('header') ?>
<?php $this->loadBlock ('mainnav') ?>
<?php $this->loadBlock ('spotlight-1') ?>
<?php $this->loadBlock ('mainbody') ?>
<?php $this->loadBlock ('spotlight-2') ?>
<?php $this->loadBlock ('spotlight-3') ?>
<?php $this->loadBlock ('navhelper') ?>
<?php $this->loadBlock ('footer') ?>
</body>
Copy templatest3_blanktplsspotlight-2.php and rename it spotlight-3.php
<?php if ($this->checkSpotlight('spotlight-3', 'position-10, position-11, position-12, position-13')) : ?>
<!-- SPOTLIGHT 3 -->
<div class="container t3-sl t3-sl-1">
<?php
$this->spotlight ('spotlight-3', 'position-10, position-11, position-12, position-13')
?>
</div>
<!-- //SPOTLIGHT 3 -->
<?php endif ?>Using your template manager edit the positions as you wish
Hope that helps
-
hrasno Friend
hrasno
- Join date:
- April 2008
- Posts:
- 38
- Downloads:
- 7
- Uploads:
- 6
- Thanks:
- 11
- Thanked:
- 2 times in 2 posts
April 19, 2015 at 6:36 pm #567518It was soooo simple, thank you 🙂
Scott Lavelle FriendScott Lavelle
- Join date:
- November 2010
- Posts:
- 266
- Downloads:
- 16
- Uploads:
- 5
- Thanks:
- 6
- Thanked:
- 64 times in 27 posts
April 21, 2015 at 1:26 am #567687Just a quick note – there is one line that still needs to be modified in that code or you will run into some styling issues that might be hard to track down:
<div class="container t3-sl t3-sl-1">
should read
<div class="container t3-sl t3-sl-3">
Scott Lavelle - Technical Resource Solutions, LLC
Certified Joomla Administrator1 user says Thank You to Scott Lavelle for this useful post
-
AuthorPosts
Viewing 4 posts - 1 through 4 (of 4 total)This topic contains 4 replies, has 3 voices, and was last updated by Scott Lavelle 9 years, 7 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Jump to forum