Question

i keep getting a sytax error when trying to add (function (e) { e.preventDefault; to

$("#pegasus-tile, #o-w, #next-pidu, #prev-bgapp").live('click',     function() {
        $("#proj-content").load("projects/pegasus.html", function() {

        $('<div id="slider" class="nivoSlider"></div>');
        $('#slider').nivoSlider({
            effect: 'sliceUpDown'
        });
    });
});

im not sure how to combine it when using .live, i know its somthing really simple but i just cant get it, any helps much apreciated

Was it helpful?

Solution

Its simple:

$("#pegasus-tile, #o-w, #next-pidu, #prev-bgapp").live('click', function( e ) {
    e.preventDefault();
    $("#proj-content").load("projects/pegasus.html", function() {

        $('<div id="slider" class="nivoSlider"></div>');
        $('#slider').nivoSlider({
            effect: 'sliceUpDown'
        });
    });
});
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top