When I try to access an article by following a link like thisindex.php?option=com_content&view=article&id=9
, the post appears as expected.
However, when I use the link index.php/2-uncategorised/9-assurance
, the front page appears instead of the article.
Why is this happening and how can I fix it?
my index.php code :
<?php if ($menu->getActive() == $menu->getDefault()): ?>
<jdoc:include type="modules" name="index" style="html5" />
<?php echo '<h1>Test</h1>' ; ?>
<?php else: ?>
<div class="container shadow p-2 mb-2 bg-white rounded">
<div class="row">
<div class="col-4"><img class="img-fluid rounded " src="templates/agmaTheme/images/demmanderDevis.jpg" /></div>
<div class="col-8 ">
<div class="shadow-sm bg-light rounded mb-2">
<div class="breadcrumbs">
<jdoc:include type="modules" name="breadcrumbs" style="html5" />
</div>
</div>
<div class="shadow-sm bg-light rounded p-1">
<jdoc:include type="component" />
</div>
</div>
</div>
</div>
<?php endif; ?>