function deleteFile ( itemID , fileRef , listName ) { // This is the command needed to delete the specified file. It uses the ID and the URL of the file name. These values must be passed into this function when calling it. var batchCmd = "<Batch OnError='Continue'><Method ID='1' Cmd='Delete'><Field Name='ID'>" + itemID + "</Field><Field Name='FileRef'>" + fileRef + "</Field></Method></Batch>" ; // Use SPServices to delete the file. $ (). SPServices ({ operation : "UpdateListItems" , async : false , listName : listName , updates : batchCmd , completefunc : function ( xData , Status ) { // Check the error codes for the web service call. $ ( xData . responseXML ). SPFilterNode ( 'ErrorCode' ). each ( function (){ responseError = $ ( this ). text (); // If the error codes indicate...