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 1017847
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T10:46:02+00:00 2026-05-16T10:46:02+00:00

I have some jQuery code that runs fine until I add the jQuery UI

  • 0

I have some jQuery code that runs fine until I add the jQuery UI library (1.7.2) and this causes the show() method to fail when I specify a callback.

$('#main.home ul#promotions').show(function() {
    if (typeof f == "function") f();
});

It would seem that jQuery UI overrides show and now I need to specify an additional parameter for “effect”, the following code fixes the issue:

$('#main.home ul#promotions').show('blind', function() {
    if (typeof f == "function") f();
});

However this is part of a script that shouldn’t be dependent on the jQuery UI library so ideally I want to stop jQuery UI overriding show in this case.

Can anyone suggest how this can be done?

Dave

  • 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-16T10:46:03+00:00Added an answer on May 16, 2026 at 10:46 am

    The normal jQuery .show() method doesn’t take a single function argument. It takes either no arguments, or a duration and an (optional) callback. Thus the jQuery UI version is compatible.

    For plain jQuery, if you’re interested in having .show() happen immediately, I think you can pass a null zero as the first argument. However, I don’t see why you’d do that; if you don’t want to animate then .show() is synchronous, and you can just put your “callback” code right after calling it. In other words, there’s no point to a callback in that case.

    edit — as the boundlessly knowledgeable Mr Craver points out, a call to .show() with just a function is like calling it with .show("normal", theFunction). It’s unfortunate that the jQuery UI code apparently messes that up, but you can code with “normal” as the first argument and you should be OK.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have some jQuery code that runs on every $(document).ready() event. I also have
I have some jquery code that is doing an ajax lookup and returning comma
I have some jQuery code that highlights a link when clicked, and changes the
I have some jQuery code that intercepts links clicked on a page: $(document).ready(function() {
I have some jQuery code that is having difficulty running because I'm using it
I have the following block of jQuery code that I'm using to copy some
Trying to get comfortable with jQuery and I have encountered some sample code that
I have a jquery line of code that outputs some HTML to a div.
I have some jQuery code like this : $(function($) { $('input.autonumeric').autoNumeric({aSep: ',', aDec: '.',vMax:'1000000000000'});
I have some jQuery that runs on a page. As a short-term fix I

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.