source: extensions/stripped_black_bloc/admin/upgrade.inc.php @ 23569

Last change on this file since 23569 was 23569, checked in by flop25, 8 years ago

adding a new option for the mouseover effect

File size: 1.9 KB
Line 
1<?php
2
3if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
4
5global $prefixeTable, $conf;
6
7if (!isset($conf['stripped_black_bloc']))
8{
9  $config = array(
10  'color_main'            => 'E6554F',
11  'column_width'            => 170,
12  'thumbnail_width'           => 150,
13  'every_x'           => 20,
14  'starting_to'           => 1,
15  'catthumb'         => 'none', //none - same - all
16  'orientation_option'         => 'none', //none - max_heigth - big_landscape
17  'hover_action'         => 'fadein', //fadein - fadeout - border - none
18  );
19  $query = "
20INSERT INTO " . CONFIG_TABLE . " (param,value,comment)
21VALUES ('stripped_black_bloc' , '".pwg_db_real_escape_string(serialize($config))."' , 'color_main#column_width#thumbnail_width#catthumb(none - same - all)');";
22  pwg_query($query);
23  load_conf_from_db();
24}
25elseif (count(unserialize( $conf['stripped_black_bloc'] ))!=8)
26{
27  $conff=unserialize($conf['stripped_black_bloc']);
28  $config = array(
29  'color_main'            => (isset($conff['color_main'])) ? $conff['color_main'] :'E6554F',
30  'column_width'            => (isset($conff['column_width'])) ? $conff['column_width'] :170,
31  'thumbnail_width'           => (isset($conff['thumbnail_width'])) ? $conff['thumbnail_width'] :150,
32  'every_x'           => (isset($conff['every_x'])) ? $conff['every_x'] : 20,
33  'starting_to'           => (isset($conff['starting_to'])) ? $conff['starting_to'] :1,
34  'catthumb'         => (isset($conff['catthumb'])) ? $conff['catthumb'] :'none', //none - same - all
35  'orientation_option'         => (isset($conff['orientation_option'])) ? $conff['orientation_option'] :'none', //none - max_heigth -big_landscape
36  'hover_action'         => (isset($conff['hover_action'])) ? $conff['hover_action'] :'fadein' //fadein - fadeout - border - none
37  );
38  conf_update_param('stripped_black_bloc', pwg_db_real_escape_string(serialize($config)));
39  load_conf_from_db();
40}
41?>
Note: See TracBrowser for help on using the repository browser.