Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Beginner 28 posts 78 karma points
    Sep 05, 2013 @ 15:16
    Beginner
    0

    Problem with jquery in a menu

    Hello:)

    I have been playing with a css template http://chocotemplates.com/corporate/curve/ to learn how to implement i new stylesheet.

    I got a problem with the jquery. My umbraco has a mainpage that has menu and the menu has a 2ndlevelmenu too. It looks like this. mainpage (has a menu) --Child(has a menu) ------child(last page)

    But when I run the last child page i mobileview its like the page does not load the jquery for the menu? I can not find it in "firebug". It just says "No JavaScript on this page".

    I have added this in my header:

    <script src="js/functions.js" type="text/javascript"></script>
    

    The jquery looks like this:

    $(function () {
    $(document).on('focusin', '.field, textarea', function () {
        if (this.title == this.value) {
            this.value = '';
        }
    }).on('focusout', '.field, textarea', function () {
        if (this.value == '') {
            this.value = this.title;
        }
    });
    
    $('#navigation ul li:first-child').addClass('first');
    
    $('.footer-nav ul li:first-child').addClass('first');
    
    $('#navigation a.nav-btn').click(function () {
        $(this).closest('#navigation').find('ul').slideToggle()
        $(this).find('span').toggleClass('active')
        return false;
    })
    

    });

    $(window).load(function () { $('.flexslider').flexslider({ animation: "slide", controlsContainer: ".slider-holder", slideshowSpeed: 5000, directionNav: false, controlNav: true, animationDuration: 2000, before: function (slider) { $('.img-holder').animate({ 'bottom': '-30px' }, 300) },

        after: function (slider) {
            $('.img-holder').animate({ 'bottom': '0px' }, 300)
        }
    });
    

    });

    Do you have any ideas??

    Regards..

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies