I'm pretty new to JQuery, as you can tell by my question...

The user can append many new input fields to the form. This works great, but how can they delete a specific field? If they append 5 input fields, how do they delete lets say the third field?

Below is my following code. What is currently does is always delete the first item when clicked.

```
        $("#addNewItem").click(function(){
            $("#invoice_items").append('<input type="text" name="name[]" value="name" id="item_name" class="item_name" /><a href="#" id="delete_input"><img src="images/delete.png" /></a>');
        });

        $("#delete_input").live("click", function(){
            $("#item_name").remove();
            $(this).remove();
        });

```