1 <% include('elements/search.html',
3 'name_singular' => 'member',
5 'count_query' => $count_query,
6 'header' => [ 'Email address' ],
7 'fields' => [ $email_sub, ], #just this one for now
8 'html_init' => $html_init,
14 #make sure the mailing list is attached to a customer service i can see/view
16 $cgi->param('listnum') =~ /^(\d+)$/ or die 'illegal listnum';
19 my $mailinglist = qsearchs('mailinglist', { 'listnum' => $listnum })
20 or die "unknown listnum $listnum";
21 my $title = $mailinglist->listname. ' mailing list';
24 'table' => 'mailinglistmember',
25 'hashref' => { 'listnum' => $listnum },
28 my $count_query = "SELECT COUNT(*) FROM mailinglistmember WHERE listnum = $listnum";
32 my $r = $member->email; #just this one for now
33 my $a = qq[<A HREF="javascript:areyousure('$r', ]. $member->membernum. ')">';
34 $r .= " (${a}remove</A>)";
38 my $html_init = <<"END";
39 <SCRIPT TYPE="text/javascript">
40 function areyousure(email,membernum) {
41 if ( confirm('Are you sure you want to remove ' + email + ' from this mailing list?') )
42 window.location.href="${p}misc/delete-mailinglistmember.html?" + membernum;