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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T22:28:08+00:00 2026-06-14T22:28:08+00:00

here is a very simplified example of what happened jQuery(.resultAction).each(makeItso); function makeItso() { //code

  • 0

here is a very simplified example of what happened

jQuery(".resultAction").each(makeItso);

function makeItso() {
    //code executes (it was a conditional to test for a file extension and display apply a class)
    //the short version:
    jQuery(this).find("#indicator").addClass("is" + fileExtension.slice(1));

    //no file extension hide the icon div "indicator"
    if ((fileExtension.indexOf('.') == -1)) {
        jQuery(this).find("#indicator").addClass("not");
    }

}

Now, this worked well and it worked faster than .ready() -as I had about 100 results per page.

but there was one bug: on the last element it did not execute -so, I did this to re-run the function on that last item after the page loaded:

jQuery(document).ready(function(){
    jQuery(".resultAction:last").each(makeItso);
});

So, to make a long story short this worked well, in Firefox, IE 7,8, 9 -though HERE is the interesting part: I tested using a Mac and VMware Fusion, sop I “thought” I was OK, the testers used their PC’s and IE 8 –Epic fail.

I leaned something: #1 testing on a Virtual machine is NOT the same as the real deal. Also my Question is why did this crash In IE 8 and otherwise run fine in 9 and in Fox? Did I code badly?

  • 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-06-14T22:28:09+00:00Added an answer on June 14, 2026 at 10:28 pm

    It looks like you have an element with id="indicator" inside every .resultAction. Each ID should be unique on the page. Some browsers may not care about this restriction. Others might.

    Change the id="indicator" to be class="indicator" and it may help.

    As for your other problem, that it isn’t executing on the last row, you don’t need to wait for document.ready as long as you make sure the script comes later in the HTML than the elements it is manipulating. I.e. put the <script> tag last thing before the body. If you are doing this and it isn’t working, we’ll definitely need to see the full html.

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

Sidebar

Related Questions

So I've noticed some very weird behaviour from my program. Here's a simplified code
Here's my proposed (very simplified to illustrate the problem space) design for a C#
Here's a very quick example for my problem: http://img19.imageshack.us/img19/3575/workertool.png (I'm not allowed to post
Here's a very simple program using the function: #include <windows.h> #include <tchar.h> #include <atlstr.h>
Very confused here, trying out the yuicompressor on a simple javascript file. My js
Here's a problem I experience (simplified example): Let's say I have several tables: One
I'm working on a Gran Turismo 5 Django application. Here's a very simplified data
The examples here show a very simplified version of a VIEW that I am
I made a research and all posts here are very blury regarding this issue.
Here is a very simple program: a = [[]]*3 print str(a) a[0].append(1) a[1].append(2) a[2].append(3)

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.