Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6574461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T15:15:53+00:00 2026-05-25T15:15:53+00:00

I already asked this question in the jQuery forum but I didn’t get an

  • 0

I already asked this question in the jQuery forum but I didn’t get an answer. I’ve got a problem with the initialization of the jScrollPane plugin. I set up a test site to illustrate it: http://herrmondl.multimediaart.at/_notwebsite/test/test.html

Clicking on a picture should update the entire left DIV. The first time you click on a picture works well but repeating this process makes the “Bio” section disappear. This is definitely because of a wrong initialization of the jScrollPane plugin.
If you (re)load the website and click on Urkel at first you’ll see the custom scrollbar.

So here’s the buggy code for calling the hover and click events:

$('div.artistImg a').hover(function() {

    var currArtist = $(this).parent().find('div.artistName'),
        clicked = $(currArtist).hasClass('artistActive');

    if (!clicked) {
        $(currArtist).stop().css('top', '30px').show().animate({
            "top": "0px"
        }, "fast");
    }
}, function() {
    // if(!$clicked) {
    //       $(currArtist).stop()
    //           .css({
    //               'display': 'block',
    //               'top':'0px'
    //               })
    //           .animate({"top": "30px"}, "fast");    
}).bind('click', function(e) {
    $('div.artistActive').removeClass('artistActive');
    $(this).parent().find('div.artistName').addClass('artistActive');

    $('.artistWrap .artistDates').css('display', 'none');
    e.preventDefault();
    $("div.firstDates").hide().html($(this.hash).html()).fadeIn('slow');


    var api = $('.artistBio').jScrollPane({
        showArrows: false,
        verticalGutter: '1',
    });
    api.reinitialise();
});

Basically this code handles a hover animation and the click event. As you can see in the code it should also handle the mouse-out animation which also seems not to work.

Any help to get the initialization right would be appreciated (and if you get the mouse-out stuff working too you will be my hero).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T15:15:54+00:00Added an answer on May 25, 2026 at 3:15 pm

    I figured it out on my own some time ago. It seems that my .html()-method caused the problem. Using .load() works just fine. So here is the updated code

    $(function() {
    
        $('.artistBio').jScrollPane().data('jsp');
    
        $('div.artistImg a').hover(function(){
    
            ...
    
            },function(){
    
                ...
    
            }).bind('click',
                function(e)
                {
                    $('div.artistActive').removeClass('artistActive');
                    $(this).parent().find('div.artistName').addClass('artistActive');
    
                    $('.artistWrap .artistDates').css('display', 'none');
                    e.preventDefault(); 
    
    
    
                    // retrieve the current file's url as .load() seems to need it
                    var file = location.pathname.substr(location.pathname.lastIndexOf("/")+1,location.pathname.length);
    
                    $("div.firstDates").hide().load(file + " " + this.hash, 
                            function()
                            {
                                $('.artistBio').jScrollPane().data('jsp').reinitialise();
                            }).fadeIn("slow");
    
    
    
                }
    
        );
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I already asked this question but I didn't get my answer. Btw I found
Introduction: I asked this question on the P2-forum already but I couldnt get any
This question is already asked in this forum but I don't understand the concept.
I already asked this question, but I didn't explain it too well, so I
I've already asked this question, but I think I din't explain the problem well
I have already asked this question in offical Flot google groups, but got no
Yes, I have already asked this question, but the problem is much more specific.
I already asked this question but at that time I tought that the refresh
I've already asked this question on several forums, but without any good explanation of
I am sorry I have already asked this question on Superuser, but nobody answers

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.