We moved to new unified forum!

Please post all new support queries in our New Forum.

T3 Community Discussion & Support

Let's build the best free Joomla template framework, together!
  1. Lee Tempest
  2. Sherlock Holmes
  3. General Discussion
  4. Friday, 17 July 2015
  5.  Subscribe via email
I'm trying to achieve something in my template and hope you can help!

Within my custom mainbody.php, I'm trying to load different widths of the main body dependent on if a module is loaded to the sidebar:

<?php if ($this->countModules('sidebar-1')) :
echo '<div id="t3-content" class="t3-content col-lg-8 col-md-8 col-sm-12 col-xs-12">'
else;
echo '<div id="t3-content" class="t3-content col-lg-12 col-md-12 col-sm-12 col-xs-12">';
endif ?>

But this completely fails and does not display anything.

What am I doing wrong?

Thanks

SOLUTION
My code above is wrong use:

<?php if ($this->countModules('sidebar-1')) {
echo '<div id="t3-content" class="t3-contenty col-lg-8 col-md-8 col-sm-12 col-xs-12">';
} else {
echo '<div id="t3-content" class="t3-content col-lg-12 col-md-12 col-sm-12 col-xs-12">';
} ?>

This will then make the t3-content area full width when no sidebar module is loaded.

Hope that helps
Comment
There are no comments made yet.
Accepted Answer Pending Moderation
0
Votes
Undo
Great work @Lee
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 1
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.