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

  • SEARCH
  • Home
  • 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 7630973
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T06:14:03+00:00 2026-05-31T06:14:03+00:00

I have this very simple jQuery script, which gives me error that delay is

  • 0

I have this very simple jQuery script, which gives me error that delay is not a function.

What am I doing wrong? Thing is that everything works, except that delay is causing error :S

I made sure I’m loading only jquery library once, which is also latest version 1.7.1

function    statusInquiry(orderItemID)
{
    var loadUrl = "bl_updaInfo.php";

    $.post(  
        loadUrl,
        {"orderItemID": orderItemID, "type": "statusInquiry"},
        function(responseText){
            $("#reportArea" + orderItemID).fadeIn("slow").html(responseText);
        },
        "html"  
    );
    updateLogList(orderItemID);

    $("#reportArea" + orderItemID).delay(10000).fadeOut("slow");
}

ERROR I’m getting:
– [19:44:10.792] $("#reportArea" + orderItemID).delay is not a function

responseText is exactly this:

<table class="tablerainbow-noborder" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td style="color: #888786;" width="70%">Client requests status for this search.</td>
<td style="color: #888786;">Posted 2012-03-12 12:34:22 by Client</td>
</tr>
</tbody>
</table>
  • 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-31T06:14:05+00:00Added an answer on May 31, 2026 at 6:14 am

    You are passing in a string value. Have you tried passing in a number (without the quotes)?

    Also, are you sure you’re using this the way it was intended? According to the jQuery API docs, delay affects the next animation in the queue, not the ones that have already been executed.

    Ultimately, the answer depends on what you want to do. The fadeOut command will not be affected by the call to delay if delay appears after the fadeOut in the call chain. If you want to pause for a bit before the fadeOut occurs, then you’ll need to switch the two calls around.

    EDIT: More thoughts based on some interaction with @Adrov.

    From the jQuery API docs for post, you might want to take a look at the contents of the responseText object when it goes into the success callback. If you are putting a complete page of HTML into an existing div tag, you’ll end up with conflicts and odd behaviors. The example below is straight from the jQuery docs. Notice how a find is executed on the results before putting the data into the existing page.

    $.post( url, { s: term },
          function( data ) {
              var content = $( data ).find( '#content' );
              $( "#result" ).empty().append( content );
          }
        );
    

    EDIT NOTE: Ken Redler’s answer suggests to chain the delay and fadeOut methods inside the success callback for the post method. I just want to make sure that this suggestion doesn’t get lost, as it’s a very good suggestion.

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

Sidebar

Related Questions

I have this jQuery simple code: <script type=text/javascript> <!-- jQuery(function(){ jQuery('#old_thumb').click(function(){ $(this).val($(this).attr('title')); $('#sf').val('2'); $('#add_new_event').submit();
I have this very simple example that I am using to learn structs in
I have this html page which is very simple, it contains a text box
Let's say I have a very simple PrototypeJS class that looks like this: var
I have written a simple jQuery script that changes the hash tag of a
I have a very simple script that slides a message down from the top
I have a simple jQuery function that resizes text areas, and I want it
I have a very simple jQuery/ajax script for a membership driven website. The script
I'm not really a javascript/jquery coder, I have a very simple code to remove
I have programmed a very simple script with jQuery. The idea is to fade

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.