action.php 574 B

1234567891011121314151617181920212223
  1. <?php
  2. global $_,$conf;
  3. switch($_['action']){
  4. //Reset des paramètres du thème
  5. case 'customiser_reset_theme':
  6. global $myUser,$_,$conf;
  7. User::check_access('customiser','configure');
  8. if(file_exists(__DIR__.SLASH.'css'.SLASH.'theme.css'))
  9. unlink(__DIR__.SLASH.'css'.SLASH.'theme.css');
  10. header('location: setting.php?section=global.customiser');
  11. break;
  12. case 'customiser_theme_save':
  13. Action::write(function(&$response){
  14. global $myUser,$_,$conf;
  15. User::check_access('customiser','configure');
  16. $conf->put('core_theme',$_['theme']);
  17. });
  18. break;
  19. }
  20. ?>