source: extensions/autoupdate/trunk/ajax/ignore_list.php @ 9735

Last change on this file since 9735 was 9735, checked in by patdenice, 13 years ago

Remove useless function.
Update englich language key.

File size: 1011 bytes
Line 
1<?php
2
3define('PHPWG_ROOT_PATH','../../../');
4define('IN_ADMIN', true);
5include_once( PHPWG_ROOT_PATH.'include/common.inc.php' );
6include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
7
8check_status(ACCESS_ADMINISTRATOR);
9check_pwg_token();
10
11if (isset($_POST['reset']))
12{
13  $conf['AU_ignore'] = array('plugins'=>array(),'themes'=>array(),'languages'=>array());
14  conf_update_param('autoupdate_ignore_list', pwg_db_real_escape_string(serialize($conf['AU_ignore'])));
15  unset($_SESSION['extensions_need_update']);
16  echo 'ok';
17  exit;
18}
19
20if (empty($_POST['id']) or empty($_POST['type'])
21  or !in_array($_POST['type'], array('plugins', 'themes', 'languages')))
22{
23  die;
24}
25
26// Add or remove plugin from ignore list
27if (!in_array($_POST['id'], $conf['AU_ignore'][$_POST['type']]))
28{
29  array_push($conf['AU_ignore'][$_POST['type']], $_POST['id']);
30}
31conf_update_param('autoupdate_ignore_list', pwg_db_real_escape_string(serialize($conf['AU_ignore'])));
32unset($_SESSION['extensions_need_update']);
33echo 'ok';
34
35?>
Note: See TracBrowser for help on using the repository browser.