Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • philingbb Friend
    #178650

    Hi,

    I would like to add this script in the header:

    <script type=”text/javascript”>
    window.addEvent(‘domready’,function() {
    new SmoothScroll({ duration:700 }, window);
    });
    </script>

    Template: Puresite
    Joomla 2.5

    Thanks
    Philippe

    Saguaros Moderator
    #459480

    Hi there,

    If you wanna add script like yours above or google ananlytics, …. You should override default.php file of JAT3 plugin for your default template as follow:
    Copy the file plugins>system>jat3>jat3>base-themes>default>page>default.php into templates>ja_your-template-name>page>default.php and insert your analytics code just before the </head> tag as per below.

    <head>
    ************YOUR SCRIPT HERE *************
    <?php //gen head base on theme info
    $this->showBlock ('head');
    ?>
    <?php
    $blocks = T3Common::node_children($this->getBlocksXML ('head'), 'block');
    foreach ($blocks as $block) :
    $this->showBlock ($block);
    endforeach;
    ?>

    <?php echo $this->showBlock ('css') ?>

    </head>

    spaziogiovani Friend
    #496367

    Worked for me!
    thanks.

    Saguaros Moderator
    #496375

    You are welcome :laugh:

    alendonald Friend
    #498058

    Always a script add in the head part.

    philingbb Friend
    #499872

    <em>@Saguaros 328140 wrote:</em><blockquote>Hi there,

    If you wanna add script like yours above or google ananlytics, …. You should override default.php file of JAT3 plugin for your default template as follow:
    Copy the file plugins>system>jat3>jat3>base-themes>default>page>default.php into templates>ja_your-template-name>page>default.php and insert your analytics code just before the </head> tag as per below.

    <head>
    ************YOUR SCRIPT HERE *************
    <?php //gen head base on theme info
    $this->showBlock ('head');
    ?>
    <?php
    $blocks = T3Common::node_children($this->getBlocksXML ('head'), 'block');
    foreach ($blocks as $block) :
    $this->showBlock ($block);
    endforeach;
    ?>

    <?php echo $this->showBlock ('css') ?>

    </head>
    </blockquote>

    Thanks, I will try it.
    Philippe

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

This topic contains 6 replies, has 4 voices, and was last updated by  philingbb 11 years, 3 months ago.

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