Ignore:
Timestamp:
Jul 13, 2012, 12:12:21 PM (12 years ago)
Author:
mistic100
Message:

-separate "archive_comment" in a new config parameter
-confirmation message before start download

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/BatchDownloader/include/events.inc.php

    r16609 r16689  
    8181        $BatchDownloader->createNextArchive(true); // make sure we have only one zip, even if 'max_size' is exceeded
    8282       
    83         $u_download = BATCH_DOWNLOAD_PATH . 'download.php?set_id='.$BatchDownloader->getParam('set_id').'&zip=1';
     83        $u_download = BATCH_DOWNLOAD_PATH . 'download.php?set_id='.$BatchDownloader->getParam('id').'&zip=1';
    8484       
    8585        $null = null;
     
    9191      else
    9292      {
    93         redirect(BATCH_DOWNLOAD_PUBLIC . 'init_zip&set_id='.$BatchDownloader->getParam('set_id'));
     93        redirect(BATCH_DOWNLOAD_PUBLIC . 'init_zip&set_id='.$BatchDownloader->getParam('id'));
    9494      }
    9595    }
     
    106106 
    107107  // toolbar button
    108   $button = '<li><a href="'. $url .'&amp;action=advdown_set" title="'.l10n('Download all pictures of this selection').'" class="pwg-state-default pwg-button" rel="nofollow">
    109                         <span class="pwg-icon" style="background:url(\'' . BATCH_DOWNLOAD_PATH . 'template/zip.png\') center center no-repeat;">&nbsp;</span><span class="pwg-button-text">'.l10n('Batch Downloader').'</span>
     108  $button = '<li><a href="'. $url .'&amp;action=advdown_set" title="'.l10n('Download all pictures of this selection').'" class="pwg-state-default pwg-button" rel="nofollow"
     109    onClick="return confirm(\''.sprintf(l10n('Confirm the download of %d pictures?'), count($page['items'])).'\');">
     110                        <span class="pwg-icon batch-downloader-icon" style="background:url(\'' . BATCH_DOWNLOAD_PATH . 'template/zip.png\') center center no-repeat;">&nbsp;</span><span class="pwg-button-text">'.l10n('Batch Downloader').'</span>
    110111                </a></li>';
    111112  $template->concat('PLUGIN_INDEX_ACTIONS', $button);
     
    163164     
    164165      array_push($data, array(
    165         'URL' => BATCH_DOWNLOAD_PUBLIC . 'init_zip&amp;set_id='.$BatchDownloader->getParam('set_id'),
     166        'URL' => BATCH_DOWNLOAD_PUBLIC . 'init_zip&amp;set_id='.$BatchDownloader->getParam('id'),
    166167        'TITLE' => str_replace('"', "'", strip_tags($set['COMMENT'])),
    167168        'NAME' => $set['sNAME'],
Note: See TracChangeset for help on using the changeset viewer.