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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T04:15:33+00:00 2026-06-01T04:15:33+00:00

I am creating a page which dynamically creates input fields using jquery on the

  • 0

I am creating a page which dynamically creates input fields using jquery on the click of add button. It is working for Input field but not working for select field. The select field is as it is repeated without the change of name field. So iam having problem in getting these details via $_GET. Plz give a solution asap.

<head>
    <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
<link href="nietsms.css" rel="stylesheet" type="text/css" />

    <title> NIET Store Management System BY SDC </title>
    <script type="text/javascript" src="http://cachefile.net/scripts/jquery/1.2.3/jquery-1.2.3.min.js"></script>



    <script type="text/javascript">
        $(function(){
            var newRowNum = 0;
            $('#addnew').click(function(){
                newRowNum += 1;
                var addRow = $(this).parent().parent();
                var newRow = addRow.clone();
                $('input', addRow).val('');
                $('td:first-child', newRow).html(newRowNum);
                $('input', newRow).each(function(i){
                    var newID = newRowNum + '_' + i;
                    $(this).attr('id',newID).attr('name',newID);
                });






                addRow.before(newRow);
  • 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-01T04:15:36+00:00Added an answer on June 1, 2026 at 4:15 am

    Replace

    $('input', addRow) 
    

    and

    $('input', newRow) 
    

    with

    $(":input", addRow) 
    

    and

    $(':input', newRow).
    

    $("input") returns only nodes of type “input”, while “:input” is a jQuery pseudoselector which targets inputs, selects, options etc.

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

Sidebar

Related Questions

I'm working on a page on which I'm dynamically creating a Facebook Like button
My page creates rows dynamically using jQuery but when I refresh the form, the
I'm creating an dynamic image, which creates headers on my page using PHPs GD-library.
I am adding HTML input controls on the page dynamically via a add text
i'm creating a web page which contains a few dynamically generated images. in my
I am working on a asp.net application in which i am creating a page
I'm creating DOM elements dynamically (more specifically, using jQuery to create a DIV containing
I am creating few pages (including login page) which should only be accessible by
I am creating a login register page which contains two edit text boxes(one for
I am creating a 404.html page in django which will be called when 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.