I am trying to call a function called gallery_image_slider() from within the $(document).ready(function() function.
Here is what I tried, but doesn't work.
$(document).ready(function() {
gallery_image_slider();
});
function slider() {
$('.projects_gallery ol').click(function() {
$("p.projects_gallery ol:first").addClass("intro");
});
function gallery_image_slider() {
$('.project_desc_2').hide();
$('#project2').hide();
$('#description2').hide();
$('#project1').hover(function() {
$('#description1').show();
$('.project_desc_1').show();
$('.project_desc_2').hide();
$('#description2').hide();
});
$('#project2').hover(function() {
$('#description2').show();
$('.project_desc_2').show();
$('.project_desc_1').hide();
});
$('#project1').mouseleave(function() {
$('.project_desc_2').hide();
$('#description2').hide();
});
$('#project2').mouseleave(function() {
$('.project_desc_1').hide();
$('#description1').hide();
});
}
}
How can I do this and also, how do I call multiple functions within another function?