Answer the question
In order to leave comments, you need to log in
How to make two columns (sidebar + content) in bootstrap for cms joomla?
There was already a similar question on the site (
https://toster.ru/q/138149 )
).
Answer the question
In order to leave comments, you need to log in
<?php $sidebarModule = !!$this->countModules('sidebar'); ?>
<div class="container">
<div class="row">
<?php if ($sidebarModule) : ?>
<div class="col-md-4">
<jdoc:include type="modules" name="sidebar" />
</div>
<?php endif; ?>
<div class="col-md-<?php echo ($sidebarModule ? 8 : 12); ?>">
<jdoc:include type="component" />
</div>
</div>
</div>
Thanks for the reply Evgeny Kumanin .
Doesn't work as expected.
The code that the engine produces:
<div class="container">
<div class="row">
<div class="col-md-4">
<div class="custom" >
<div class="sidebar_l">
Текст сайдбара
</div>
</div>
</div>
<div class="col-md-8">
<div class="item-page">
<div class="page-header">
<h1>Заголовок статьи</h1>
<div>Текст статьи</div>
</div>
</div>
</div>
</div>
</div>
<div class="item-page">
<div class="page-header">
<h1>Заголовок статьи</h1>
<div class="container">
<div class="row">
<div class="col-md-4">
<div class="custom" >
<div class="sidebar_l">
Текст сайдбара
</div>
</div>
</div>
<div class="col-md-8">
<div>Текст статьи</div>
</div>
</div>
</div>
</div>
</div>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question