Question: I have a excel with multiple tabs and the name of the sheets coming as 

> 
> sheet0, sheet1, .... sheet10
> 
> 
> 

I wanted to rename those tabs how to do it in UNIX shell using **ksh** or **bash**.

Please note that by tabs of excel , my context is the name of excel sheet that is getting displayed at bottom of excel.for generating excel I am using array with syntax `{arrayelements [*]}` under a while loop.

Answer: 
Give this a try:

```
    // Display confirmation dialog  
    $('td a.delete-slideshow-image').click(function (e) {
        window.tr = $(this).parents('tr'); // store the 'TR' in a global variable, no need for the keyword 'var'
        var imageId = $(this).data('id'); // use data-id='$image_id' in your HTML table
        var modal = '<div id="deleteSlideshowConfirmation" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="dataConfirmLabel" aria-hidden="true">' + 
            '<div class="modal-dialog">' +
            '<div class="modal-content">' +
            '<div class="modal-header">' +
            '<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>' +
            '<h4 class="modal-title">Delete Confirmation</h4>' +
            '</div>' +
            '<div class="modal-body"></div>' +
            '<div class="modal-footer">' +
            '<button class="btn" data-dismiss="modal" aria-hidden="true">Cancel</button>' +
            '<a class="btn btn-primary slideshowConfirmOk" data-id="' + imageId + '">Delete</a>' +
            '</div>' +
            '</div>' +
            '</div>' +
            '</div>'; // put your modal content in a variable

        $(modal).find('.modal-body').text($(this).attr('data-confirm'));

        $(modal).modal({ // then use jQuery selector on that variable to make it show, no need for appending to the body
            show: true
        });
        return false;

        e.preventDefault();
    });
    // separate the two click handlers
    $(document).on('click', 'a.slideshowConfirmOk', function () { // use $(document) to dyanmically bind the event on your confirm button
            var id = $(this).data('id'); // use data-id="'+imageId+'" in your modal
            var data = 'imageId=' + id;
            // var parent = $(this).parents('tr'); << this is useless now

            console.log(data);

            $.ajax({
                type: "POST",
                url: "delete_row.php",
                data: data,
                cache: false,

                success: function () {
                    $('#deleteSlideshowConfirmation.modal').modal('hide'); // hide modal on ajax success
                    window.tr.fadeOut('slow', function () { // use the global variable here to fade it out
                        $(this).remove();
                    });
                }
            });
        });

```

How this works for you?
As you said that you are generating table dynamically so what is happening over there. Jquery ready function bind the events on elements after DOM loaded, in your case it could not bind event on your target elements. Try to change the syntax of click event like as below.

```
$(document).on('click','td a.delete-slideshow-image', function(e) {

//Your code

})

```

And in your ajax call

```
$( document ).on('click',"a.slideshowConfirmOk", function() {  
//AJAX code
})

```

Main key thing is bind your events on document when you're working on elements dynamically. 
I assume you've included jquery's latest version.