Changeset 28849


Ignore:
Timestamp:
06/29/14 16:25:59 (5 years ago)
Author:
mistic100
Message:

use new maintain class

Location:
extensions/SmiliesSupport
Files:
1 added
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/SmiliesSupport/admin.php

    r26075 r28849  
    3232  $conf['smiliessupport'] = array( 
    3333    'folder' =>       $_POST['folder'], 
    34     'cols' =>         preg_match('#^([0-9]+)$#', $_POST['cols']) ? $_POST['cols'] : 6, 
     34    'cols' =>         preg_match('#^[0-9]+$#', $_POST['cols']) ? $_POST['cols'] : 6, 
    3535    'representant' => $sets[ $_POST['folder'] ], 
    3636  ); 
    3737   
    38   conf_update_param('smiliessupport', serialize($conf['smiliessupport'])); 
     38  conf_update_param('smiliessupport', $conf['smiliessupport']); 
    3939  $page['infos'][] = l10n('Information data registered in database'); 
    4040   
  • extensions/SmiliesSupport/main.inc.php

    r27208 r28849  
    1414define('SMILIES_DIR',     SMILIES_PATH . 'smilies/'); 
    1515define('SMILIES_ADMIN',   get_root_url() . 'admin.php?page=plugin-' . SMILIES_ID); 
    16 define('SMILIES_VERSION', 'auto'); 
    17  
    1816 
    1917include_once(SMILIES_PATH.'include/functions.inc.php'); 
     
    4139  global $conf; 
    4240   
    43   include_once(SMILIES_PATH . 'maintain.inc.php'); 
    44   $maintain = new SmiliesSupport_maintain(SMILIES_ID); 
    45   $maintain->autoUpdate(SMILIES_VERSION, 'install'); 
    46    
    47   $conf['smiliessupport'] = unserialize($conf['smiliessupport']); 
     41  $conf['smiliessupport'] = safe_unserialize($conf['smiliessupport']); 
    4842  $conf['smiliessupport_ext'] = array('gif', 'jpg', 'png', 'GIF', 'JPG', 'PNG'); 
    4943   
Note: See TracChangeset for help on using the changeset viewer.