// JavaScript Document
$(function() {
            $("#customerTable tbody tr:odd").addClass("altrow");
            $("#customerTable tbody tr:even").addClass("row");

            $("#customerTable tbody td:last-child").each(function() {
                //Create a new clipboard client
                var clip = new ZeroClipboard.Client();

                //Cache the last td and the parent row    
                var lastTd = $(this);
                var parentRow = lastTd.parent("tr");

                //Glue the clipboard client to the last td in each row
                clip.glue(lastTd[0]);

                //Grab the text from the parent row of the icon
                /*var txt = $.trim($("td:first-child", parentRow).text()) + "\r\n" + $.trim($("td:nth-child(2)", parentRow).text()) + "\r\n" +
                $.trim($("td:nth-child(3)", parentRow).text()) + "\r\n" + $.trim($("td:nth-child(4)", parentRow).text());*/
				var txt = $.trim($("td:first-child", parentRow).text());
                clip.setText(txt);

                //Add a complete event to let the user know the text was copied
                clip.addEventListener('complete', function(client, text) {
                    alert("Ce texte a été copié dans le presse papier : " + text);
					runword();
                });
            });
        });   
