hpdl
|
1133
|
1
|
<?php
|
|
2
|
/*
|
|
3
|
$Id: $
|
|
4
|
|
|
5
|
osCommerce, Open Source E-Commerce Solutions
|
|
6
|
http://www.oscommerce.com
|
|
7
|
|
hpdl
|
1453
|
8
|
Copyright (c) 2007 osCommerce
|
hpdl
|
1133
|
9
|
|
hpdl
|
1497
|
10
|
This program is free software; you can redistribute it and/or modify
|
|
11
|
it under the terms of the GNU General Public License v2 (1991)
|
|
12
|
as published by the Free Software Foundation.
|
hpdl
|
1133
|
13
|
*/
|
|
14
|
?>
|
|
15
|
|
hpdl
|
1405
|
16
|
<h1><?php echo osc_link_object(osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule()), $osC_Template->getPageTitle()); ?></h1>
|
hpdl
|
1133
|
17
|
|
|
18
|
<?php
|
|
19
|
if ($osC_MessageStack->size($osC_Template->getModule()) > 0) {
|
hpdl
|
1845
|
20
|
echo $osC_MessageStack->get($osC_Template->getModule());
|
hpdl
|
1133
|
21
|
}
|
|
22
|
?>
|
|
23
|
|
hpdl
|
1475
|
24
|
<div class="infoBoxHeading"><?php echo osc_icon('trash.png') . ' ' . $osC_Language->get('action_heading_batch_delete_cards'); ?></div>
|
hpdl
|
1133
|
25
|
<div class="infoBoxContent">
|
hpdl
|
1405
|
26
|
<form name="ccDeleteBatch" action="<?php echo osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule() . '&page=' . $_GET['page'] . '&action=batchDelete'); ?>" method="post">
|
hpdl
|
1133
|
27
|
|
hpdl
|
1453
|
28
|
<p><?php echo $osC_Language->get('introduction_batch_delete_cards'); ?></p>
|
hpdl
|
1133
|
29
|
|
|
30
|
<?php
|
|
31
|
$Qcc = $osC_Database->query('select id, credit_card_name from :table_credit_cards where id in (":id") order by credit_card_name');
|
|
32
|
$Qcc->bindTable(':table_credit_cards', TABLE_CREDIT_CARDS);
|
|
33
|
$Qcc->bindRaw(':id', implode('", "', array_unique(array_filter(array_slice($_POST['batch'], 0, MAX_DISPLAY_SEARCH_RESULTS), 'is_numeric'))));
|
|
34
|
$Qcc->execute();
|
|
35
|
|
|
36
|
$names_string = '';
|
|
37
|
|
|
38
|
while ($Qcc->next()) {
|
|
39
|
$names_string .= osc_draw_hidden_field('batch[]', $Qcc->valueInt('id')) . '<b>' . $Qcc->valueProtected('credit_card_name') . '</b>, ';
|
|
40
|
}
|
|
41
|
|
|
42
|
if ( !empty($names_string) ) {
|
hpdl
|
1202
|
43
|
$names_string = substr($names_string, 0, -2);
|
hpdl
|
1133
|
44
|
}
|
|
45
|
|
|
46
|
echo '<p>' . $names_string . '</p>';
|
|
47
|
?>
|
|
48
|
|
hpdl
|
1475
|
49
|
<p align="center"><?php echo osc_draw_hidden_field('subaction', 'confirm') . '<input type="submit" value="' . $osC_Language->get('button_delete') . '" class="operationButton" /> <input type="button" value="' . $osC_Language->get('button_cancel') . '" onclick="document.location.href=\'' . osc_href_link_admin(FILENAME_DEFAULT, $osC_Template->getModule() . '&page=' . $_GET['page']) . '\';" class="operationButton" />'; ?></p>
|
hpdl
|
1133
|
50
|
|
|
51
|
</form>
|
|
52
|
</div>
|