Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • jscarfe Friend
    #194590

    I’m trying to add something like a mass-top module inside the Main Content section of a block (an example being “one-sidebar-right.php”. I’ve added a new position called “custom” in the TemplateDetails XML file and have added to following code to the php file:

    [PHP] <!– MAIN CONTENT –>
    <div id=”t3-content” class=”t3-content col-xs-12 col-sm-8 col-md-9″>

    <?php if ($this->countModules($custom)) : ?>
    <!– CUSTOM –>
    <div class=”custom”>
    <jdoc:include type=”modules” name=”<?php $this->_p($vars[‘custom’]) ?>” style=”T3Xhtml” />
    </div>
    <!– //CUSTOM –>
    <?php endif ?>

    <?php if($this->hasMessage()) : ?>
    <jdoc:include type=”message” />
    <?php endif ?>
    <jdoc:include type=”component” />

    </div>
    <!– //MAIN CONTENT –>[/PHP]

    I’ve created a custom html module using the “custom” position, but the module isn’t showing on the page. I’m guessing I’m missing a step somewhere. Any guidance would be greatly appreciated!

    Thanks in advance!

    Scott Lavelle Friend
    #521801

    When I add an extra position, I usually have a line that looks like this:


    <jdoc:include type="modules" name="<?php $this->_p('header-info') ?>" style="raw" />

    In your example, what is the $vars part?

    Scott Lavelle - Technical Resource Solutions, LLC
    Certified Joomla Administrator

    jscarfe Friend
    #521840

    Perfect! Your code did the trick! The one thing I’m still unsure about is how to include the module’s title.

    Scott Lavelle Friend
    #521847

    You should be able to do that at the module itself. In the module config, there is an option for show or don’t for the module Title. In Joomla 3.2.1, this option is on the Module tab on the top of the far right and says “show title” with options for show or hide.

    Does that help?

    Scott Lavelle - Technical Resource Solutions, LLC
    Certified Joomla Administrator

    jscarfe Friend
    #521861

    Yup. The module’s title is published. If it helps, this is regarding the t3_bs3 template.

    Scott Lavelle Friend
    #521866

    Hmmm. I haven’t been using the t3-bs3 template yet except for on one test site. I have been trying to catch up on some sites that I have already started with the previous bs2 template and, if you haven’t noticed, you can’t just switch templates in the middle without doing some work to convert. I’ll try to take a look at the test site I have and see if I can find what the issue is.

    Do you have a public link to the site you are working on?

    Scott Lavelle - Technical Resource Solutions, LLC
    Certified Joomla Administrator

    jscarfe Friend
    #521867

    I’m just testing on a local wamp. I’ll keep digging as well, and thanks for checking when you have a moment.

    Scott Lavelle Friend
    #521869

    for what it’s worth, I just recreated my test container and the module title worked as I expected it to. In this case, I just created a single Position1 module and have it showing on the home page right under the main menu. The ability to turn on and of the module title worked as expected as described above.

    Scott Lavelle - Technical Resource Solutions, LLC
    Certified Joomla Administrator

    jscarfe Friend
    #521870

    I found the issue. I updated the jdoc style to “T3Xhtml” from “raw” and the title is now showing. Thanks again for all your help!

    Scott Lavelle Friend
    #521871

    Yeah – I’ve not really tried to understand the different options there, whether T3Xhtml or raw or whatever. If someone wants to chime in, it would be helpful to the community.

    Scott Lavelle - Technical Resource Solutions, LLC
    Certified Joomla Administrator

Viewing 10 posts - 1 through 10 (of 10 total)

This topic contains 10 replies, has 2 voices, and was last updated by  Scott Lavelle 10 years, 9 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum