This repository has been archived on 2024-01-19. You can view files and clone it, but cannot push or open issues or pull requests.
epubreader/ajax/personal.php

36 lines
788 B
PHP
Raw Normal View History

2020-04-21 20:37:42 +00:00
<?php
/**
* ownCloud - Epubreader App
2020-04-21 20:37:42 +00:00
*
* @author Frank de Lange
* @copyright 2014,2018 Frank de Lange
*
* This file is licensed under the Affero General Public License version 3 or
* later.
*/
namespace OCA\Epubreader;
2020-04-21 20:37:42 +00:00
\OC_JSON::callCheck();
\OC_JSON::checkLoggedIn();
$l = \OC::$server->getL10N('epubreader');
2020-04-21 20:37:42 +00:00
$EpubEnable = isset($_POST['EpubEnable']) ? $_POST['EpubEnable'] : 'false';
$PdfEnable = isset($_POST['PdfEnable']) ? $_POST['PdfEnable'] : 'false';
$CbxEnable = isset($_POST['CbxEnable']) ? $_POST['CbxEnable'] : 'false';
Config::set('epub_enable', $EpubEnable);
Config::set('pdf_enable', $PdfEnable);
Config::set('cbx_enable', $CbxEnable);
\OC_JSON::success(
array(
'data' => array('message'=> $l->t('Settings updated successfully.'))
)
);
exit();