Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • nini891 Friend
    #725191

    I came across an issue while trying to add custom javascript to my purity III.

    I’m trying to achive to have the same height of sidebars and content (.t3-sidebar-1, .t3-sidebar-2 and .t3-content) based on the height of the tallest one of those 3.
    I’m using this plugin https://github.com/liabru/jquery-match-height.
    I’ve added the following code to my ‘../templates/purity_iii/tpls/blocks/head.php’ in order to include the script and invoke it. I’m not sure what I’m doing wrong becuase it’s not tossing any errors but it’s not working as well.

    Can anyone please help me out with this?

    Temp URL: http://div-programi.hr/ombudsman.hr/

    The included code in head.php:

    <script src="/ombudsman.hr/templates/purity_iii/js/jquery.matchHeight.js" type="text/javascript"></script>
    <script type="text/javascript">
    (function() {
    $(function() {
    $('.container').each(function() {
    $(this).children('.t3-content, .t3-sidebar-1, .t3-sidebar-2').matchHeight({
    property: 'min-height'
    });
    });
    });
    })();
    </script>

    Manos Moderator
    #725273

    Hi,
    Did you try implementing JQuery noconflict ?

    Maybe that’s a way to go 🙂

    Regards

    Manos Moderator
    #754990

    Hi,
    Did you try implementing JQuery noconflict ?

    Maybe that’s a way to go 🙂

    Regards

    nini891 Friend
    #725368

    Thank you for your reply.

    I’ve tried adding noconflict but it looks like it didn’t help.
    Did I even include the plugin correctly in purity III ?
    I’ve tried everything what I could think of so there must be something that I’m doing wrong.

    I’m including my head.php file so you can see what I did, maybe you can see ‘the error of my ways’ 😀

    nini891 Friend
    #755028

    Thank you for your reply.

    I’ve tried adding noconflict but it looks like it didn’t help.
    Did I even include the plugin correctly in purity III ?
    I’ve tried everything what I could think of so there must be something that I’m doing wrong.

    I’m including my head.php file so you can see what I did, maybe you can see ‘the error of my ways’ 😀

    nini891 Friend
    #755152

    Anyone?
    I’m still stuck with this, don’t have any more ideas what’s preventing it from running or why it isn’t running correctly. :/

    Saguaros Moderator
    #755451

    You should test with default Joomla template first and see whether that script works or not.

    pierrest Friend
    #941124

    Hi there, it’s old but anyway, lost one hour to fix it.

    just put your custom jquery like there

    if (jQuery) {
    jQuery(document).ready(function($) {

       // your jquery here
    
    });

    };

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

This topic contains 6 replies, has 3 voices, and was last updated by  pierrest 8 years, 5 months ago.

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