Changeset 28919


Ignore:
Timestamp:
Jul 2, 2014, 3:34:46 PM (10 years ago)
Author:
plg
Message:

feature 2616: remove useless code (photos_add_direct_process or uploadify related variables)

Location:
trunk/admin
Files:
2 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/include/photos_add_direct_prepare.inc.php

    r28533 r28919  
    2222// +-----------------------------------------------------------------------+
    2323
    24 
    25 // +-----------------------------------------------------------------------+
    26 // | Uploaded photos                                                       |
    27 // +-----------------------------------------------------------------------+
    28 
    29 if (isset($page['thumbnails']))
    30 {
    31   $template->assign(
    32     array(
    33       'thumbnails' => $page['thumbnails'],
    34       )
    35     );
    36 
    37   // only display the batch link if we have more than 1 photo
    38   if (count($page['thumbnails']) > 1)
    39   {
    40     $template->assign(
    41       array(
    42         'batch_link' => $page['batch_link'],
    43         'batch_label' => sprintf(
    44           l10n('Manage this set of %d photos'),
    45           count($page['thumbnails'])
    46           ),
    47         )
    48       );
    49   }
    50 }
    51 
    5224// +-----------------------------------------------------------------------+
    5325// | Photo selection                                                       |
    5426// +-----------------------------------------------------------------------+
    55 
    56 $uploadify_path = PHPWG_ROOT_PATH.'admin/include/uploadify';
    5727
    5828$upload_max_filesize = min(
     
    7343    array(
    7444      'F_ADD_ACTION'=> PHOTOS_ADD_BASE_URL,
    75       'uploadify_path' => $uploadify_path,
    7645      'upload_max_filesize' => $upload_max_filesize,
    7746      'upload_max_filesize_shorthand' => $upload_max_filesize_shorthand,
     
    11887
    11988
    120 $upload_modes = array('html', 'multiple');
    121 $upload_mode = isset($conf['upload_mode']) ? $conf['upload_mode'] : 'multiple';
    122 
    123 if (isset($_GET['upload_mode']) and $upload_mode != $_GET['upload_mode'] and in_array($_GET['upload_mode'], $upload_modes))
    124 {
    125   $upload_mode = $_GET['upload_mode'];
    126   conf_update_param('upload_mode', $upload_mode);
    127 }
    128 
    129 // what is the upload switch mode
    130 $index_of_upload_mode = array_flip($upload_modes);
    131 $upload_mode_index = $index_of_upload_mode[$upload_mode];
    132 $upload_switch = $upload_modes[ ($upload_mode_index + 1) % 2 ];
    133 
    134 $template->assign(
    135     array(
    136       'upload_mode' => $upload_mode,
    137       'form_action' => PHOTOS_ADD_BASE_URL.'&upload_mode='.$upload_mode.'&processed=1',
    138       'switch_url' => PHOTOS_ADD_BASE_URL.'&upload_mode='.$upload_switch,
    139       'upload_id' => md5(rand()),
    140       'session_id' => session_id(),
     89$template->assign(
     90    array(
     91      'form_action' => PHOTOS_ADD_BASE_URL,
    14192      'pwg_token' => get_pwg_token(),
    142       'another_upload_link' => PHOTOS_ADD_BASE_URL.'&upload_mode='.$upload_mode,
    14393    )
    14494  );
     
    152102}
    153103
    154 if ('html' == $upload_mode)
     104if (false) // TODO manage zip files in pwg.images.upload
    155105{
    156106  $upload_file_types.= ', zip';
     
    279229    array(
    280230      'setup_warnings' => $setup_warnings,
    281       'hide_warnings_link' => PHOTOS_ADD_BASE_URL.'&upload_mode='.$upload_mode.'&hide_warnings=1'
     231      'hide_warnings_link' => PHOTOS_ADD_BASE_URL.'&hide_warnings=1'
    282232      )
    283233    );
  • trunk/admin/photos_add_direct.php

    r26461 r28919  
    5959
    6060// +-----------------------------------------------------------------------+
    61 // |                             process form                              |
    62 // +-----------------------------------------------------------------------+
    63 
    64 include_once(PHPWG_ROOT_PATH.'admin/include/photos_add_direct_process.inc.php');
    65 
    66 // +-----------------------------------------------------------------------+
    6761// |                             prepare form                              |
    6862// +-----------------------------------------------------------------------+
Note: See TracChangeset for help on using the changeset viewer.