test
Viewing 15 posts - 1 through 15 (of 22 total)
  • Author
    Posts
  • montgomeryr Friend
    #1050709

    In a previous post HERE, Pankaj Sharma created a block for me called "masthead". I noticed there was an update to my Fixel Template so I installed that update to my site. After doing so the "masthead" block is no longer there. I see the file under tpls/blocks/ but it’s not listed in the admin panel under the fixed template and when I load my site of course the content I had set for that block is missing.

    Would you kindly please add it back like you did before? Thank You!

    Notice my website was moved to another hosting server and the IP address has changed. See details below.

    Saguaros Moderator
    #1051017

    Hi,

    Kindly follow that topic and apply the solution into ‘local’ folder, if you changed in default /tpls/ directory in template folder, it will be overwritten when updating new version.

    Regards

    montgomeryr Friend
    #1051096

    I didn’t change anything. He was the one that created and set this up for me. I tried to follow the instructions he gave me but those instructions are not complete and do not give step by step of what to do an how. I spent 3 hours trying to figure it out and could not do so. Please contact Pankaj Sharma and have him to redo what the template update removed. I need to get my site live ASAP and did not expect it to get removed when I updated my template. It also needs setup so that the next update it will not be removed like this time.

    And when you say ‘local’ what in the world does that mean? I need to know the actual location that folder should be created at and does the folder need to be named "local"? You need to be more specific with yours instructions!

    Saguaros Moderator
    #1051107

    Hi,

    I re-open that topic, you can ask Pankaj again for what he did on your site for details.

    With the ‘local’ folder inside template, for each template built with T3 framework, you can add your customization inside this folder so that when you update new version for template, this custom work will not be affected. Check out this docs for more info: http://www.t3-framework.org/documentation/extend-com-content#isolate-template

    Regards

    montgomeryr Friend
    #1051125

    That other topic is still closed! I can not post anything into it.

    Pankaj Sharma Moderator
    #1051127

    Hi
    Sorry for my late reply I have not got the information of this thread.I just jumped into this thread.
    For the new module position :

    I checked your site and it still has the masthead position showing fine.
    Kindly check it again.
    I also noticed the override is in the local folder. of the test site.
    You can copy the file "/tpls/blocks/masthead.php" in template "ja_fixel". to your new site.
    and then copy the /tpls/default.php and home.php and copy the same on the new site.
    http://prntscr.com/fzo2np
    Now open the local folder and paste the above two file in it with the same path.
    By adding the files in the local folder they are not overridden on template update.

    Hope it helps.

    Regards

    montgomeryr Friend
    #1051177

    I am afraid you were still pointing to the old server. Since you worked on my site last they have moved me to a new server. You need to point test.shoals.k12.in.us to IP address: 38.86.76.85

    Then you will see the masthead is not working anymore. I actually had modules displayed using the masthead block but now they are gone after the template update. Can you please fix it and make it so that when the new updates are applied it does not remove it again? Thanks!

    Pankaj Sharma Moderator
    #1051186

    Hi Can you apply the suggestion given here. This way you can get the position back on new site. You only need to copy the file from older site to new site with same path.
    And you have the position back on site.
    Regards

    montgomeryr Friend
    #1051858

    Do I place the "masthead.php" file in the local folder as well? or does that go in the tpls/blocks/ location?

    Pankaj Sharma Moderator
    #1051862

    Hi
    Yes, add the files in same location for an override.
    /local/tpls/blocks/ masthead.php
    and /local/tpls/home.php and default.php

    Regards

    montgomeryr Friend
    #1051866

    Ok, Did that and I got that block back. I was lucky I still had access to the other server so I could pull those files and copy them over the the new server.

    Now I am trying to duplicate the masthead block right below that block and calling it "events"
    I have my events.php file under local/tpls/blocks with this code in the file:
    <?php
    /**

    • @package T3 Blank
    • @copyright Copyright (C) 2005 – 2012 Open Source Matters, Inc. All rights reserved.
    • @license GNU General Public License version 2 or later; see LICENSE.txt
      */

    defined(‘_JEXEC’) or die;
    ?>

      <?php if ($this->countModules(‘events’)) : ?>
    <div class="container t3events <?php $this->_c(‘events’) ?>" style="
    padding-top: 20px;">
            <jdoc:include type="modules" name="<?php $this->_p(‘events’) ?>" />
    </div>

    <?php endif ?>

    I have added <?php $this->loadBlock (‘events’) ?> in the home.php file under local/tpls
    I have added <?php $this->loadBlock (‘events’) ?> in the default.php file under local/tpls
    When I go into my template settings and layout in the admin panel it says it can’t find the block. What am I doing wrong? See Image.


    1. Screen-Shot-2017-07-27-at-12.31.08-AM
    Pankaj Sharma Moderator
    #1051886

    Hi
    Kindly add events.php file in the tpls/blocks folder first
    Local folder is an override for the files that already present in the template folder.

    Regards

    montgomeryr Friend
    #1052017

    I placed that file in that location and still getting the block not found message as in my previous screen shot.

    Pankaj Sharma Moderator
    #1052100

    Hi
    You are using default.php layout from the local folder but you have not defined the blocks in the /tpls/blocks/default.php
    http://prntscr.com/g193ls
    Kindly add them also use the correct code as showing below
    In your code there is syntax error.

    
        <?php $this->loadBlock ('masthead') ?>
    
        <?php $this->loadBlock ('events') ?>

    Hope it helps.

    Regards

    montgomeryr Friend
    #1052409

    In this file: local/tpls/default.php I have this in the code:
    <?php $this->loadBlock (‘header’) ?>

    <?php $this->loadBlock ('masthead') ?>
    <?php $this->loadBlock (‘events’) ?>
    <?php $this->loadBlock ('mainbody') ?>

    I have this file: local/tpls/blocks/events.php I have this in the code:
    defined(‘_JEXEC’) or die;
    ?>

      <?php if ($this->countModules(‘events’)) : ?>
    <div class="container t3events <?php $this->_c(‘events’) ?>" style="
    padding-top: 0px;">
            <jdoc:include type="modules" name="<?php $this->_p(‘events’) ?>" />
    </div>

    <?php endif ?>

    I DO not have a default.php file in local/tpls/blocks/ Am I suppose to?

Viewing 15 posts - 1 through 15 (of 22 total)

This topic contains 21 replies, has 3 voices, and was last updated by  Pankaj Sharma 7 years, 5 months ago.

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