- Timestamp:
- Mar 11, 2010, 11:03:23 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/nbc_HistoryIPExcluder/trunk/admin/HIPE_admin.php
r5099 r5113 3 3 if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); 4 4 5 //include_once(get_language_filepath('plugin.lang.php', NBC_HISTORYIPEXCLUDER_PATH));6 5 load_language('plugin.lang', HIPE_PATH); 7 6 8 7 9 8 $ip_geolocalisation1 = '<a href="http://www.geoiptool.com/fr/?IP='; 10 $ip_geolocalisation2 = '" title="Geo IP localisation" target="_blank"><img src="'.HIPE_PATH.'/geoip.ico" class="button" alt="'.l10n(' nbc_IP_geolocalisation').'"></a>';9 $ip_geolocalisation2 = '" title="Geo IP localisation" target="_blank"><img src="'.HIPE_PATH.'/geoip.ico" class="button" alt="'.l10n('IP_geolocalisation').'"></a>'; 11 10 12 11 $ip_ripe1 = '<a href="http://www.ripe.net/whois?form_type=simple&full_query_string=&searchtext='; … … 21 20 $v = str_replace( "\r\n", ",", $v ); 22 21 $v = str_replace( ",,", ",", $v ); 23 24 $conf['nbc_HistoryIPExcluder'] = serialize($v); 25 //$conf['nbc_HistoryIPExcluder'] = stripslashes($v); 22 23 $conf['nbc_HistoryIPExcluder'] = stripslashes($v); 26 24 27 25 $query = ' 28 26 UPDATE '.CONFIG_TABLE.' 29 SET value="'. addslashes($conf['nbc_HistoryIPExcluder']).'"27 SET value="'.$conf['nbc_HistoryIPExcluder'].'" 30 28 WHERE param="nbc_HistoryIPExcluder" 31 29 LIMIT 1'; … … 33 31 34 32 // information message 35 array_push($page['infos'], $lang['HIPE_save_config']);33 array_push($page['infos'], l10n('HIPE_save_config')); 36 34 } 37 35 elseif ( isset($_POST['CleanHist']) ) 38 36 { 39 $conf_HIPE = unserialize($conf['nbc_HistoryIPExcluder']); 40 //$conf_nbc_HistoryIPExcluder = explode("," , $conf['nbc_HistoryIPExcluder']); 37 $conf_HIPE = explode("," , $conf['nbc_HistoryIPExcluder']); 41 38 42 39 foreach ( $conf_HIPE as $Exclusion ) … … 59 56 60 57 // information message 61 array_push($page['infos'], $lang['HIPE_hist_cleaned']);58 array_push($page['infos'], l10n('HIPE_hist_cleaned')); 62 59 } 63 60 elseif ( isset($_POST['HIPE_IPByMember']) ) … … 65 62 $template->assign( 66 63 array( 67 'HIPE_DESCRIPTION2' => $lang['HIPE_IPByMember_description'],64 'HIPE_DESCRIPTION2' => l10n('HIPE_IPByMember_description'), 68 65 ) 69 66 ); … … 200 197 } 201 198 202 203 $conf_HIPE = unserialize($conf['nbc_HistoryIPExcluder']); 204 //$conf_nbc_HistoryIPExcluder = explode("," , $conf['nbc_HistoryIPExcluder']); 199 $conf_HIPE = explode("," , $conf['nbc_HistoryIPExcluder']); 205 200 206 201 $template->assign( 207 202 array( 208 203 'HIPE_F_ACTION' => PHPWG_ROOT_PATH.'admin.php?page=plugin§ion=nbc_HistoryIPExcluder%2Fadmin%2FHIPE_admin.php', 209 'IPs_EXCLUDED' => $conf_HIPE,204 'IPs_EXCLUDED' => implode("\n", $conf_HIPE), 210 205 ) 211 206 ); … … 214 209 $template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content'); 215 210 216 //$template->set_filenames( array('plugin_admin_content' => HIPE_PATH.'admin/nbc_HistoryIPExcluder_admin.tpl') );217 218 //$template->assign_var_from_handle( 'ADMIN_CONTENT', 'plugin_admin_content');219 220 211 ?>
Note: See TracChangeset
for help on using the changeset viewer.