hpdl
|
1125
|
1
|
<?php
|
|
2
|
/*
|
|
3
|
$Id: $
|
|
4
|
|
|
5
|
osCommerce, Open Source E-Commerce Solutions
|
|
6
|
http://www.oscommerce.com
|
|
7
|
|
|
8
|
Copyright (c) 2006 osCommerce
|
|
9
|
|
|
10
|
Released under the GNU General Public License
|
|
11
|
*/
|
|
12
|
?>
|
|
13
|
|
hpdl
|
1405
|
14
|
<h1><?php echo osc_link_object(osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule()), $osC_Template->getPageTitle()); ?></h1>
|
hpdl
|
1125
|
15
|
|
|
16
|
<?php
|
|
17
|
if ($osC_MessageStack->size($osC_Template->getModule()) > 0) {
|
|
18
|
echo $osC_MessageStack->output($osC_Template->getModule());
|
|
19
|
}
|
|
20
|
?>
|
|
21
|
|
|
22
|
<div class="infoBoxHeading"><?php echo osc_icon('trash.png', IMAGE_DELETE) . ' Batch Delete'; ?></div>
|
|
23
|
<div class="infoBoxContent">
|
hpdl
|
1405
|
24
|
<form name="aDeleteBatch" action="<?php echo osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule() . '&page=' . $_GET['page'] . '&action=batchDelete'); ?>" method="post">
|
hpdl
|
1125
|
25
|
|
|
26
|
<p><?php echo TEXT_DELETE_BATCH_INTRO; ?></p>
|
|
27
|
|
|
28
|
<?php
|
|
29
|
$Qadmins = $osC_Database->query('select id, user_name from :table_administrators where id in (":id") order by user_name');
|
|
30
|
$Qadmins->bindTable(':table_administrators', TABLE_ADMINISTRATORS);
|
|
31
|
$Qadmins->bindRaw(':id', implode('", "', array_unique(array_filter(array_slice($_POST['batch'], 0, MAX_DISPLAY_SEARCH_RESULTS), 'is_numeric'))));
|
|
32
|
$Qadmins->execute();
|
|
33
|
|
|
34
|
$names_string = '';
|
|
35
|
|
|
36
|
while ($Qadmins->next()) {
|
|
37
|
$names_string .= osc_draw_hidden_field('batch[]', $Qadmins->valueInt('id')) . '<b>' . $Qadmins->value('user_name') . '</b>, ';
|
|
38
|
}
|
|
39
|
|
|
40
|
if ( !empty($names_string) ) {
|
hpdl
|
1200
|
41
|
$names_string = substr($names_string, 0, -2);
|
hpdl
|
1125
|
42
|
}
|
|
43
|
|
|
44
|
echo '<p>' . $names_string . '</p>';
|
|
45
|
?>
|
|
46
|
|
hpdl
|
1200
|
47
|
<p align="center"><?php echo osc_draw_hidden_field('subaction', 'confirm') . '<input type="submit" value="' . IMAGE_DELETE . '" class="operationButton" /> <input type="button" value="' . IMAGE_CANCEL . '" onclick="document.location.href=\'' . osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule() . '&page=' . $_GET['page']) . '\';" class="operationButton" />'; ?></p>
|
hpdl
|
1125
|
48
|
|
|
49
|
</form>
|
|
50
|
</div>
|