aboutsummaryrefslogtreecommitdiffstats
path: root/themes/smartpocket/admin/upgrade.inc.php
blob: 34ab43dcc5bf56ffc81549991072909a1fb55a6a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?php

if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');

global $prefixeTable, $conf;

if (!isset($conf['smartpocket']))
{
  $config = array(
    'loop'            => true,//true - false
    'autohide'            => 5000,//5000 - 0
  );
  conf_update_param('smartpocket', pwg_db_real_escape_string(serialize($config)));
  load_conf_from_db();
}
elseif (count(unserialize( $conf['smartpocket'] ))!=2)
{
  $conff=unserialize($conf['smartpocket']);
  $config = array(
    'loop'            => (isset($conff['loop'])) ? $conff['loop'] :true,
    'autohide'            => (isset($conff['autohide'])) ? $conff['autohide'] :5000,
  );
  conf_update_param('smartpocket', pwg_db_real_escape_string(serialize($config)));
  load_conf_from_db();
}
?>