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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T10:55:17+00:00 2026-06-11T10:55:17+00:00

I am creating a jQuery array but my code keeps returning [object Object], 3

  • 0

I am creating a jQuery array but my code keeps returning [object Object], 3 times.

Here is my code:

var idArray = [];
$('.taskPHP').each(function() {
  var idStr = { 
    'taskPHPid': $(this).attr('id'), 
    'taskValue': $(this).val() 
  }
  idArray.push(idStr);
});

alert(idArray);

EDIT:
Just call me stupid…i knew i couldn’t alert an array. err…to many beers and programming don’t mix.

I will give u credit as soon as I can. Thanks for the help.

  • 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-11T10:55:18+00:00Added an answer on June 11, 2026 at 10:55 am

    Seems fine, try console.log and see what it outputs, or alert(JSON.stringify(idArray))

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

Sidebar

Related Questions

So basically here is my jQuery and HTML code for creating arrays. It basically
i am dynamically creating radio using jquery as shown belown. but they value only
I wanted to create jquery plugin & started off creating a sample jquery plugin...But
I have simple AJAX function that uses jQuery to return an array of 300
I want to execute some code only when all images in a jQuery object
Im stuck with a ajax function im creating. Here is the deal, I have
I'm creating a table with images using jQuery. My js code looks like this:
my first post here. I'm not new to JQuery, but I find complex coding
Here's my PHP code called during jQuery AJAX call: <?php include '../code_files/conn.php'; $conn =
Might seem like a stupid question, but I'm having an issue creating an array

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.