Skip to content

Commit 867f0ba

Browse files
committed
Initialize Discuz_X3.2_SC_UTF8 20150609
0 parents  commit 867f0ba

File tree

4,119 files changed

+426134
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,119 files changed

+426134
-0
lines changed

admin.php

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
<?php
2+
3+
/**
4+
* [Discuz!] (C)2001-2099 Comsenz Inc.
5+
* This is NOT a freeware, use is subject to license terms
6+
*
7+
* $Id: admin.php 34285 2013-12-13 03:39:35Z hypowang $
8+
*/
9+
10+
define('IN_ADMINCP', TRUE);
11+
define('NOROBOT', TRUE);
12+
define('ADMINSCRIPT', basename(__FILE__));
13+
define('CURSCRIPT', 'admin');
14+
define('HOOKTYPE', 'hookscript');
15+
define('APPTYPEID', 0);
16+
17+
18+
require './source/class/class_core.php';
19+
require './source/function/function_misc.php';
20+
require './source/function/function_forum.php';
21+
require './source/function/function_admincp.php';
22+
require './source/function/function_cache.php';
23+
24+
$discuz = C::app();
25+
$discuz->init();
26+
27+
$admincp = new discuz_admincp();
28+
$admincp->core = & $discuz;
29+
$admincp->init();
30+
31+
32+
$admincp_actions_founder = array('templates', 'db', 'founder', 'postsplit', 'threadsplit', 'cloudaddons', 'upgrade', 'patch', 'optimizer');
33+
$admincp_actions_normal = array('index', 'setting', 'members', 'admingroup', 'usergroups', 'usertag',
34+
'forums', 'threadtypes', 'threads', 'moderate', 'attach', 'smilies', 'recyclebin', 'recyclebinpost', 'prune', 'grid',
35+
'styles', 'addons', 'plugins', 'tasks', 'magics', 'medals', 'google', 'announce', 'faq', 'ec',
36+
'tradelog', 'jswizard', 'project', 'counter', 'misc', 'adv', 'logs', 'tools', 'portalperm', 'blogrecyclebin',
37+
'checktools', 'search', 'article', 'block', 'blockstyle', 'blockxml', 'portalcategory', 'blogcategory', 'albumcategory', 'topic', 'credits',
38+
'doing', 'group', 'blog', 'feed', 'album', 'pic', 'comment', 'share', 'click', 'specialuser', 'postsplit', 'threadsplit', 'report',
39+
'district', 'diytemplate', 'verify', 'nav', 'domain', 'postcomment', 'tag', 'connect', 'card', 'portalpermission', 'collection', 'membersplit', 'makehtml');
40+
41+
$action = preg_replace('/[^\[A-Za-z0-9_\]]/', '', getgpc('action'));
42+
$operation = preg_replace('/[^\[A-Za-z0-9_\]]/', '', getgpc('operation'));
43+
$do = preg_replace('/[^\[A-Za-z0-9_\]]/', '', getgpc('do'));
44+
$frames = preg_replace('/[^\[A-Za-z0-9_\]]/', '', getgpc('frames'));
45+
lang('admincp');
46+
$lang = & $_G['lang']['admincp'];
47+
$page = max(1, intval(getgpc('page')));
48+
$isfounder = $admincp->isfounder;
49+
50+
if(empty($action) || $frames != null) {
51+
$admincp->show_admincp_main();
52+
} elseif($action == 'logout') {
53+
$admincp->do_admin_logout();
54+
dheader("Location: ./index.php");
55+
} elseif(in_array($action, $admincp_actions_normal) || ($admincp->isfounder && in_array($action, $admincp_actions_founder))) {
56+
if($admincp->allow($action, $operation, $do) || $action == 'index') {
57+
require $admincp->admincpfile($action);
58+
} else {
59+
cpheader();
60+
cpmsg('action_noaccess', '', 'error');
61+
}
62+
} else {
63+
cpheader();
64+
cpmsg('action_noaccess', '', 'error');
65+
}
66+
?>

api.php

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<?php
2+
3+
/**
4+
* [Discuz!] (C)2001-2099 Comsenz Inc.
5+
* This is NOT a freeware, use is subject to license terms
6+
*
7+
* $Id: api.php 33591 2013-07-12 06:39:49Z andyzheng $
8+
*/
9+
10+
define('IN_API', true);
11+
define('CURSCRIPT', 'api');
12+
13+
$modarray = array('js' => 'javascript/javascript', 'ad' => 'javascript/advertisement');
14+
15+
$mod = !empty($_GET['mod']) ? $_GET['mod'] : '';
16+
if(empty($mod) || !in_array($mod, array('js', 'ad'))) {
17+
exit('Access Denied');
18+
}
19+
20+
require_once './api/'.$modarray[$mod].'.php';
21+
22+
function loadcore() {
23+
global $_G;
24+
require_once './source/class/class_core.php';
25+
26+
$discuz = C::app();
27+
$discuz->init_cron = false;
28+
$discuz->init_session = false;
29+
$discuz->init();
30+
}
31+
32+
?>

api/addons/channel.htm

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2+
<html xmlns="http://www.w3.org/1999/xhtml">
3+
<head>
4+
<meta http-equiv="content-type" content="text/html; charset=gbk" />
5+
<script type="text/javascript">
6+
var querystring = location.search.substr(1);
7+
if(querystring.indexOf('/') != -1) {
8+
var e = querystring.split('/');
9+
var url = '../../admin.php?frames=yes&action=cloudaddons&operation=download&addonids=' + e[0] + '&md5hash=' + e[1] + '&timestamp=' + e[2];
10+
try {
11+
top.location.href = url;
12+
} catch(e) {}
13+
}
14+
</script>
15+
</head>
16+
<body>
17+
</body>
18+
</html>

api/addons/index.htm

Whitespace-only changes.

api/addons/zendcheck.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
if(phpversion() >= '5.3') {
4+
include 'zendcheck53.php';
5+
} else {
6+
include 'zendcheck52.php';
7+
}
8+
9+
?>

api/addons/zendcheck52.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<?php @Zend;
2+
4123;
3+
/*

api/addons/zendcheck53.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<?php @Zend;
2+
3074;
3+
/*

api/connect/index.htm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

api/connect/like.php

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<?php
2+
3+
/**
4+
* [Discuz!] (C)2001-2099 Comsenz Inc.
5+
* This is NOT a freeware, use is subject to license terms
6+
*
7+
* $Id: like.php 25510 2011-11-14 02:22:26Z yexinhao $
8+
*/
9+
10+
define('IN_API', true);
11+
define('CURSCRIPT', 'api');
12+
13+
require_once '../../source/class/class_core.php';
14+
15+
$cachelist = array();
16+
$discuz = C::app();
17+
$discuz->init_setting = true;
18+
$discuz->init();
19+
20+
$body = '';
21+
$style = 'body { background: transparent; color: '.$_G['style']['tabletext'].'; font: '.$_G['style']['fontsize'].' '.$_G['style']['font'].'; margin:0; }'.
22+
'a { color: '.$_G['style']['link'].'; text-decoration: none; } a:hover { text-decoration: underline; }';
23+
24+
if($_G['setting']['connect']['like_allow'] && $_G['setting']['connect']['like_url']) {
25+
$style .= '#txQZ { border: medium none; float: left; height:21px; margin-top: 4px; overflow: hidden; width: 110px; }'.
26+
'.vm { vertical-align: middle; }';
27+
$body .= '<iframe id="txQZ" src="'.$_G['setting']['connect']['like_url'].'" class="vm" allowtransparency="true" scrolling="no" border="0" frameborder="0"></iframe>';
28+
}
29+
30+
if($_G['setting']['connect']['turl_allow'] && $_G['setting']['connect']['turl_code']) {
31+
$style .= '#txWB_W1 { background: url("../../static/image/common/weibo.png") no-repeat scroll 0 50% transparent; float: left; line-height: 28px; padding: 0 5px 0 20px; }'.
32+
'#txWB_W1 img { display: none; }'.
33+
'#txWB_W1 b { font-weight: 400; }'.
34+
'#txWB_W1 a { color: '.$_G['style']['highlightlink'].'; }';
35+
$body .= $_G['setting']['connect']['turl_code'];
36+
}
37+
38+
if($style && $body) {
39+
echo '<style>'.$style.'</style><body>'.$body.'</body>';
40+
}

0 commit comments

Comments
 (0)