本文整理汇总了PHP中rTorrentSettings::obtain方法的典型用法代码示例。如果您正苦于以下问题:PHP rTorrentSettings::obtain方法的具体用法?PHP rTorrentSettings::obtain怎么用?PHP rTorrentSettings::obtain使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类rTorrentSettings
的用法示例。
在下文中一共展示了rTorrentSettings::obtain方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: rTorrentSettings
if (array_key_exists($flagName, $permissions) && $permissions[$flagName]) {
$perms |= $flagVal;
}
}
$jResult .= "theWebUI.showFlags = " . $perms . ";\n";
$jResult .= "theURLs.XMLRPCMountPoint = '" . $XMLRPCMountPoint . "';\n";
$jResult .= "theWebUI.systemInfo = {};\ntheWebUI.systemInfo.php = { canHandleBigFiles : " . (PHP_INT_SIZE <= 4 ? "false" : "true") . " };\n";
if ($handle = opendir('../plugins')) {
ignore_user_abort(true);
set_time_limit(0);
@chmod('/tmp', 0777);
if (!function_exists('preg_match_all')) {
$jResult .= "log(theUILang.PCRENotFound);";
} else {
$theSettings = new rTorrentSettings();
$theSettings->obtain();
if (!$theSettings->linkExist) {
$jResult .= "log(theUILang.badLinkTorTorrent);";
$jResult .= "theWebUI.systemInfo.rTorrent = { started: false, version : '?', libVersion : '?' };\n";
} else {
$jResult .= "theWebUI.systemInfo.rTorrent = { started: true, version : '" . $theSettings->version . "', libVersion : '" . $theSettings->libVersion . "' };\n";
if ($do_diagnostic) {
$up = getUploadsPath();
$st = getSettingsPath();
@chmod($up, 0777);
@chmod($st, 0777);
@chmod('./test.sh', 0755);
if (!isUserHavePermission($theSettings->myuid, $theSettings->mygid, $up, 0x7)) {
$jResult .= "log(theUILang.badUploadsPath+' (" . $up . ")');";
}
if (!isUserHavePermission($theSettings->myuid, $theSettings->mygid, $st, 0x7)) {