|
|
@@ -34,8 +34,7 @@ function ReWriteConfigAuto() |
|
|
|
global $dsql; |
|
|
|
$configfile = DEDEDATA.'/config.cache.inc.php'; |
|
|
|
if (!is_writeable($configfile)) { |
|
|
|
echo "配置文件'{$configfile}'不支持写入,无法修改系统配置参数"; |
|
|
|
//ClearAllLink(); |
|
|
|
echo "配置文件 {$configfile} 不支持写入,无法修改系统配置参数"; |
|
|
|
exit(); |
|
|
|
} |
|
|
|
$fp = fopen($configfile, 'w'); |
|
|
@@ -90,7 +89,6 @@ else if ($action == 'view_developoer') { |
|
|
|
$offUrl = "<p>官方网址:<code>{$devInfo['offurl']}</code> <small>(复制在浏览器中打开)</small></p>"; |
|
|
|
} |
|
|
|
$authAt = date("Y-m-d", $devInfo['auth_at']); |
|
|
|
|
|
|
|
if (!isset($info['dev_id'])) { |
|
|
|
$devInfo['realname'] = $devInfo['dev_name'] = $info['team']." <span style='color:#e74d58'>未认证</span>"; |
|
|
|
$authAt = "0000-00-00"; |
|
|
@@ -108,7 +106,7 @@ else if ($action == 'setup') { |
|
|
|
ShowMsg("获取模块信息错误,模块文件可能被篡改", -1); |
|
|
|
exit; |
|
|
|
} |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br />(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br>(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$filelists = $dm->GetFileLists($hash); |
|
|
|
$filelist = ''; |
|
|
|
$prvdirs = array(); |
|
|
@@ -186,7 +184,7 @@ else if ($action == 'setup') { |
|
|
|
</td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='30'><b>目录权限检测:</b><br /> ../ 为根目录 <br /> ./ 表示当前目录</td> |
|
|
|
<td height='30'><b>目录权限检测:</b><br> ../ 为根目录 <br> ./ 表示当前目录</td> |
|
|
|
<td>$prvdir</td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
@@ -201,9 +199,9 @@ else if ($action == 'setup') { |
|
|
|
<tr> |
|
|
|
<td height='26'>对于已存在文件处理方法:</td> |
|
|
|
<td> |
|
|
|
<label><input name='isreplace' type='radio' value='1' checked='checked'>覆盖</label> |
|
|
|
<label><input name='isreplace' type='radio' value='3'>覆盖,保留副本</label> |
|
|
|
<label><input type='radio' name='isreplace' value='0'>保留旧文件</label> |
|
|
|
<label><input name='isreplace' type='radio' value='1' checked='checked'> 覆盖</label> |
|
|
|
<label><input name='isreplace' type='radio' value='3'> 覆盖,保留副本</label> |
|
|
|
<label><input type='radio' name='isreplace' value='0'> 保留旧文件</label> |
|
|
|
</td> |
|
|
|
</tr> |
|
|
|
</table>"; |
|
|
@@ -281,7 +279,7 @@ function DelModule(); |
|
|
|
else if ($action == 'del') { |
|
|
|
$dm = new DedeModule($mdir); |
|
|
|
$infos = $dm->GetModuleInfo($hash); |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br />(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br>(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$dev_id = empty($infos['dev_id'])? "<a href='{$cfg_biz_dedebizUrl}/developer' target='_blank' class='btn btn-success btn-sm'>未认证</a>" : "{$infos['dev_id']} <a href='{$cfg_biz_dedebizUrl}/developer?dev_id={$infos['dev_id']}' target='_blank' class='btn btn-success btn-sm'>未认证</a>"; |
|
|
|
$win = new OxWindow(); |
|
|
|
$win->Init("module_main.php", "js/blank.js", "post"); |
|
|
@@ -316,7 +314,7 @@ else if ($action == 'del') { |
|
|
|
<td class='dtb'><a href='module_main.php?action=showreadme&hash={$hash}' target='_blank' class='btn btn-success btn-sm'>浏览</a></td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='26' colspan='2'>删除模块仅删除这个模块的安装包文件,如果您已经安装,请执行<a href='module_main.php?hash={$hash}&action=uninstall'>卸载程序</a>来删除</td> |
|
|
|
<td height='26' colspan='2'>删除模块仅删除这个模块的安装包文件,如果您已经安装,请执行<a href='module_main.php?hash={$hash}&action=uninstall'>卸载程序</a>来删除。</td> |
|
|
|
</tr> |
|
|
|
</table>"; |
|
|
|
$win->AddMsgItem("<div style='padding-left:10px;line-height:150%'>$msg</div>"); |
|
|
@@ -338,7 +336,7 @@ else if ($action == 'uninstall') { |
|
|
|
$dm = new DedeModule($mdir); |
|
|
|
$infos = $dm->GetModuleInfo($hash); |
|
|
|
if ($infos['url'] == '') $infos['url'] = ' '; |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br />(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br>(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$filelists = $dm->GetFileLists($hash); |
|
|
|
$filelist = ''; |
|
|
|
foreach ($filelists as $v) { |
|
|
@@ -381,7 +379,7 @@ else if ($action == 'uninstall') { |
|
|
|
<td class='dtb'><a href='module_main.php?action=showreadme&hash={$hash}' target='_blank' class='btn btn-success btn-sm'>浏览</a></td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='26'>模块包含的文件:<br />(文件路径相对于当前目录)</td><td> </td> |
|
|
|
<td height='26'>模块包含的文件:<br>(文件路径相对于当前目录)</td><td> </td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='160' colspan='2'> |
|
|
@@ -391,8 +389,8 @@ else if ($action == 'uninstall') { |
|
|
|
<tr> |
|
|
|
<td height='26'>对于模块的文件处理方法:</td> |
|
|
|
<td> |
|
|
|
<label><input type='radio' name='isreplace' value='0' checked='checked'>手工删除文件,仅运行卸载程序</label> |
|
|
|
<label><input name='isreplace' type='radio' value='2'>删除模块的所有文件</label> |
|
|
|
<label><input type='radio' name='isreplace' value='0' checked='checked'> 手工删除文件,仅运行卸载程序</label> |
|
|
|
<label><input name='isreplace' type='radio' value='2'> 删除模块的所有文件</label> |
|
|
|
</td> |
|
|
|
</tr> |
|
|
|
</table>"; |
|
|
@@ -464,7 +462,7 @@ else if ($action == 'view') { |
|
|
|
$dm = new DedeModule($mdir); |
|
|
|
$infos = $dm->GetModuleInfo($hash); |
|
|
|
if ($infos['url'] == '') $infos['url'] = ' '; |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br />(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$alertMsg = ($infos['lang'] == $cfg_soft_lang ? '' : '<br>(这个模块的语言编码与您系统的编码不一致,请向开发者确认它的兼容性)'); |
|
|
|
$filelists = $dm->GetFileLists($hash); |
|
|
|
$filelist = ''; |
|
|
|
$setupinfo = ''; |
|
|
@@ -479,7 +477,7 @@ else if ($action == 'view') { |
|
|
|
} else { |
|
|
|
$setupinfo = "未安装 <a href='module_main.php?action=setup&hash={$hash}'>安装</a>"; |
|
|
|
} |
|
|
|
$dev_id = empty($infos['dev_id'])? "<a href='module_main.php?action=setup&hash={$hash}' class='btn btn-success btn-sm'>安装</a> <a href='{$cfg_biz_dedebizUrl}/developer' target='_blank' class='btn btn-success btn-sm'>未认证</a>" : "{$infos['dev_id']} <a href='{$cfg_biz_dedebizUrl}/developer?dev_id={$infos['dev_id']}' target='_blank' class='btn btn-success btn-sm'>未认证</a>"; |
|
|
|
$dev_id = empty($infos['dev_id'])? "<a href='module_main.php?action=setup&hash={$hash}' class='btn btn-success btn-sm'>安装</a><a href='{$cfg_biz_dedebizUrl}/developer' target='_blank' class='btn btn-success btn-sm' style='margin-left:6px'>未认证</a>" : "{$infos['dev_id']} <a href='{$cfg_biz_dedebizUrl}/developer?dev_id={$infos['dev_id']}' target='_blank' class='btn btn-success btn-sm'>未认证</a>"; |
|
|
|
$win = new OxWindow(); |
|
|
|
$win->Init("", "js/blank.js", ""); |
|
|
|
$wecome_info = "模块管理"; |
|
|
@@ -511,7 +509,7 @@ else if ($action == 'view') { |
|
|
|
<td class='dtb'><a href='module_main.php?action=showreadme&hash={$hash}' target='_blank' class='btn btn-success btn-sm'>浏览</a></td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='26'>模块包含的文件:<br />(文件路径相对于当前目录)</td><td> </td> |
|
|
|
<td height='26'>模块包含的文件:<br>(文件路径相对于当前目录)</td><td> </td> |
|
|
|
</tr> |
|
|
|
<tr> |
|
|
|
<td height='160' colspan='2'> |
|
|
|