#! Perl -w use strict; use CGI; my $q = new CGI; my @checkbxs = $q->param('the_name'); # only those that are checked end up in here for (@checkbxs) { &delete_file($_); # assuming a delete sub exists }