Showing a log when deleting folders and content
I'm working on my administration panels mailbox implementing a delete feature for the mailbox folders, however as I am not familiar with PHP, this is just somewhat of a simulation. Currently I simply delete the list item which was clicked of which the class '.
clicked' is applied to
- $(clicked).remove();
However I'd like to show a log such as the following;
- Moving <NUM*> e-mails from <SUB-FOLDER**> into trash folder
- Moving <NUM*> e-mails from <SUB-FOLDER**> into trash folder
- Deleting folders...
*For the simulation, this is a random number from 500-2500 of which will go up every 100.
** Goes through all sub-folders
Where I've got to so far is;
- $.confirm.deleteLog({
- 'clicked' : clicked.find('a').text()
- });
And in the function;
- $.confirm.deleteLog = function(params){
- setTimeout( function() { $('#confirmBox p .log').append(params.clicked + '<br />'); }, 1000);
- setTimeout( function() { $('#confirmBox p .log').append(params.clicked + '<br />'); }, 2000);
- setTimeout( function() { $('#confirmBox p .log').append(params.clicked + '<br />'); }, 3000);
- setTimeout( function() { $('#confirmBox p .log').append(params.clicked); }, 4000);
- };
Which produces the following;
Sub-Folder 3T-1 I-2 - I1 T-1 I-2 - I2
Sub-Folder 3T-1 I-2 - I1 T-1 I-2 - I2
Sub-Folder 3T-1 I-2 - I1 T-1 I-2 - I2
Sub-Folder 3T-1 I-2 - I1 T-1 I-2 - I2