source: extensions/Fotorama/admin.php @ 29928

Last change on this file since 29928 was 29928, checked in by JanisV, 10 years ago

Native proportions for thumbnails can be enabled

File size: 1.9 KB
Line 
1<?php
2
3defined('FOTORAMA_PATH') or die('Hacking attempt!');
4
5global $conf, $template, $page;
6
7if (isset($_POST['submit']))
8{
9  $conf['Fotorama'] = array(
10    'shadows' => isset($_POST['shadows']),
11    'only_fullscreen' => isset($_POST['only_fullscreen']),
12    'autoplay' => isset($_POST['autoplay']),
13    'stopautoplayontouch' => isset($_POST['stopautoplayontouch']),
14    'loop' => isset($_POST['loop']),
15    'enable_caption' => isset($_POST['enable_caption']),
16    'replace_picture' => isset($_POST['replace_picture']),
17    'replace_picture_only_users' => isset($_POST['replace_picture_only_users']),
18    'clicktransition_crossfade' => isset($_POST['clicktransition_crossfade']),
19    'close_button' => isset($_POST['close_button']),
20    'resize' => isset($_POST['resize']),
21    'info_button' => isset($_POST['info_button']),
22    'square_thumb' => isset($_POST['square_thumb']),
23    );
24  if (isset($_POST['allowfullscreen']))
25    $conf['Fotorama']['allowfullscreen'] = $_POST['allowfullscreen'];
26  if (isset($_POST['fit']))
27    $conf['Fotorama']['fit'] = $_POST['fit'];
28  if (isset($_POST['transition']))
29    $conf['Fotorama']['transition'] = $_POST['transition'];
30  if (isset($_POST['nav']))
31    $conf['Fotorama']['nav'] = $_POST['nav'];
32  if (isset($_POST['fullscreen_nav']))
33    $conf['Fotorama']['fullscreen_nav'] = $_POST['fullscreen_nav'];
34  if (isset($_POST['thumbheight']))
35    $conf['Fotorama']['thumbheight'] = $_POST['thumbheight'];
36  if (isset($_POST['period']))
37    $conf['Fotorama']['period'] = $_POST['period'];
38
39  conf_update_param('Fotorama', serialize($conf['Fotorama']));
40  $page['infos'][] = l10n('Information data registered in database');
41}
42
43$template->assign(array(
44  'Fotorama' => $conf['Fotorama'],
45  ));
46
47$template->set_filename('admintools_content', realpath(FOTORAMA_PATH . 'template/admin.tpl'));
48$template->assign_var_from_handle('ADMIN_CONTENT', 'admintools_content');
49
50?>
Note: See TracBrowser for help on using the repository browser.