there is my problem:
i have some toggle section. This section should show dynamical content depending on clicked trigger. So eg. by clicking "support", there should be some contact information/download support tool provided, on clicking "search" - search box etc.
My question is if it is possible to solve this with only one Module position or its need one position for each trigger?
Hope to describe this understandable =)
Any help is appreciated.
Thanks
Alex
UPD: I will try to explain with code:
Module position:
if ($this->countModules('pos-1')) :
$module = JModuleHelper::getModules( 'pos-1' );
foreach($modules as $m) : ?>
<section class="mod_%echo $m->title%">
<jdoc:include type="modules" name="pos-1" style="xhtml" />
</section>
endforeach;
endif;
And Trigger:
if ($this->countModules('pos-1')) :
$module = JModuleHelper::getModules( 'pos-1' );
foreach($module as $m) :
<a class="btn-collapse collapsed" role="button" data-toggle="collapse" data-parent="#accordion"
href="#echo $m->title;" aria-expanded="true" aria-controls=" echo $m->title;">
<i class="fa fa-building-o"></i> <? echo $m->title; ?>
</a>
endforeach;
endif;
So i have added two CustomHTML modules to this position.
Result:
<section ... class="mod_title1">
content mod_one
content mod_two
</section>
<section ... class="mod_title2">
content mod_one
content mod_two
</section>
<a ... href="#mod_title1" ...> mod_title1 </a>
<a ... href="#mod_title2" ...> mod_title2 </a>
And should be:
<section ... class="mod_title1">
content mod_one
</section>
<section ... class="mod_title2">
content mod_two
</section>
<a ... href="#mod_title1" ...> mod_title1 </a>
<a ... href="#mod_title2" ...> mod_title2 </a>
So i think this is not possible with only one position adn should be solved with many.
Please correct me if i have it wrong.
UPD2: I was wrong. This is possible but not only via Template - also module chrome tempalte should be extended with own functin to render it right.