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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T20:03:17+00:00 2026-05-11T20:03:17+00:00

Similar to: Using fadein and append But the solutions there aren’t working for me.

  • 0

Similar to: Using fadein and append

But the solutions there aren’t working for me. I’m trying:

 $('#thumbnails').append('<li><img src="/photos/t/'+data.filename+'"/></li>').hide().fadeIn(2000);

But then the whole list fades in at once, not as each item is added. It looks like hide() and fadeIn() are being applied to $('#thumbnails') not the <li>. How would I get them to apply to that instead? This doesn’t work either:

$('#thumbnails').append('<li stle="display:none"><img src="/photos/t/'+data.filename+'"/></li>').filter(':last').fadeIn(2000);

Other suggestions?

  • 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-11T20:03:17+00:00Added an answer on May 11, 2026 at 8:03 pm

    Your first attempt is very close, but remember that append() is returning #thumbnails, not the item you just added to it. Instead, construct your item first and apply the hide().fadeIn() before adding it:

    $('#thumbnails')
        .append($('<li><img src="/photos/t/'+data.filename+'"/></li>')
            .hide()
            .fadeIn(2000)
        );
    

    This uses the dollar function to construct the <li> ahead of time. You could also write it on two lines, of course, if that makes it clearer:

    var item = $('<li><img src="/photos/t/'+data.filename+'"/></li>')
        .hide()
        .fadeIn(2000);
    $('#thumbnails').append(item);
    

    Edit: Your second attempt is also almost there, but you need to use children() instead of filter(). The latter only removes nodes from the current query; your newly-added item isn’t in that query, but is a child node instead.

    $('#thumbnails')
        .append('<li style="display:none"><img src="/photos/t/'+data.filename+'"/></li>')
        .children(':last')
        .hide()
        .fadeIn(2000);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a tool that can generate diagrams (similar to Doxygen using Graphviz) but
I'm having a problem similar to jQuery $.ajax Not Working in IE8 but it
I am trying to access a static method, but using a variable as the
If I wanted to represent states or options or something similar using binary flags
I'm starting Android Market via my app to search for similar products using this
Asciidoc supports callouts . How can one write similar callouts using reStructuredText ?
And what if you want to autocomplete passwords? I am using similar thing here...
I am using very similar loops to iterate all public fields and properties of
Hi i am using HttpClient similar to this: public static Task<string> AsyncStringRequest(string url, string
I am currently using code similar to this: try { // IE ONLY var

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.