Files
web-discuz/source/plugin/replyfloor/admin/admin_language.php
2025-06-27 21:04:18 +08:00

60 lines
2.3 KiB
PHP

<?php
/**
* This is NOT a freeware, use is subject to license terms
* 应用名称: 贴吧楼中楼回复 9.0
* 下载地址: https://addon.dismall.com/plugins/replyfloor.html
* 应用开发者: 乘凉
* 开发者QQ: 594433766
* 更新日期: 202505310549
* 授权域名: www.shitangsweet.com
* 授权码: 2025053105b89RrI3R9n
* 未经应用程序开发者/所有者的书面许可,不得进行反向工程、反向汇编、反向编译等,不得擅自复制、修改、链接、转载、汇编、发表、出版、发展与之有关的衍生产品、作品等
*/
/**
* $author: 乘凉 $
*/
if(!defined('IN_DISCUZ') || !defined('IN_ADMINCP')) {
exit('Access Denied');
}
$selectlang = array('script' => '&#31243;&#24207;&#33050;&#26412;', 'template' => '&#27169;&#26495;&#39029;&#38754;');
$type = in_array($_GET['type'], array_keys($selectlang)) ? $_GET['type'] : 'script';
loadcache('pluginlanguage_'.$type, 1);
if(empty($_G['cache']['pluginlanguage_'.$type])) {
$_G['cache']['pluginlanguage_'.$type] = array();
}
if(!submitcheck('savesubmit')) {
showformheader($pluginurl.'&type='.$type);
$headertab = '';
foreach ($selectlang as $key => $value) {
if($key == $type){
$headertab .= '<div style="float:left;margin-right:10px;"><a href="'.ADMINSCRIPT.'?action='.$pluginurl.'&type='.$key.'" style="display:block;background:#555;color:#fff;padding:0 15px;line-height:25px;text-decoration:none">'.$value.'</a></div>';
}else{
$headertab .= '<div style="float:left;margin-right:10px;"><a href="'.ADMINSCRIPT.'?action='.$pluginurl.'&type='.$key.'" style="display:block;background:#ddd;padding:0 15px;line-height:25px;text-decoration:none">'.$value.'</a></div>';
}
}
showtableheader($headertab);
foreach ($_G['cache']['pluginlanguage_'.$type][$plugin['identifier']] as $key => $value) {
if($type == 'template' || ($type == 'script' && strpos($key, $plugin['identifier']) === 0)){
showsetting($key, "setting[$key]", $value, 'textarea');
}
}
showsubmit('savesubmit', 'submit');
showtablefooter();
showformfooter();
} else {
$_G['cache']['pluginlanguage_'.$type][$plugin['identifier']] = array_merge($_G['cache']['pluginlanguage_'.$type][$plugin['identifier']], $_GET['setting']);
savecache('pluginlanguage_'.$type, $_G['cache']['pluginlanguage_'.$type]);
if($type == 'template') {
cleartemplatecache();
}
cpmsg('plugins_edit_succeed', 'action='.$pluginurl.'&type='.$type, 'succeed');
}
?>