<?php

/**
 *      [Discuz!] (C)2001-2099 Comsenz Inc.
 *      This is NOT a freeware, use is subject to license terms
 *
 *      $Id: spacecp_plugin.php 22435 2011-05-09 02:09:38Z monkey $
 */
if (!defined('IN_DISCUZ')) {
    exit('Access Denied');
}
$pluginkey = 'spacecp' . ($op ? '_' . $op : '');
$navtitle = $_G['setting']['plugins'][$pluginkey][$_G['gp_id']]['name'];
include pluginmodule($_G['gp_id'], $pluginkey);
if (!$op || $op == 'credit') {
    include template('home/spacecp_plugin');
} elseif ($op == 'profile') {
    $result = DB::fetch_first("SELECT * FROM " . DB::table('common_setting') . " WHERE skey='profilegroup'");
    $defaultop = '';
    if (!empty($result['svalue'])) {
        $profilegroup = unserialize($result['svalue']);
    }
    $operation = 'plugin';
    include template('home/spacecp_profile');
}
Example #2
0
<?php

/**
 *      [Discuz!] (C)2001-2099 Comsenz Inc.
 *      This is NOT a freeware, use is subject to license terms
 *
 *      $Id: spacecp_plugin.php 6752 2010-03-25 08:47:54Z cnteacher $
 */
if (!defined('IN_DISCUZ')) {
    exit('Access Denied');
}
include pluginmodule($_G['gp_id'], 'spacecp' . ($op ? '_' . $op : ''));
if (!$op || $op == 'credit') {
    include template('home/spacecp_plugin');
} elseif ($op == 'profile') {
    $operation = 'plugin';
    include template('home/spacecp_profile');
}
Example #3
0
<?php

/**
 *      [Discuz!] (C)2001-2099 Comsenz Inc.
 *      This is NOT a freeware, use is subject to license terms
 *
 *      $Id: modcp_plugin.php 25246 2011-11-02 03:34:53Z zhangguosheng $
 */
if (!defined('IN_DISCUZ') || !defined('IN_MODCP')) {
    exit('Access Denied');
}
$modtpl = $_GET['id'];
include pluginmodule($_GET['id'], 'modcp_' . $op);
Example #4
0
<?php

/**
 *      [Discuz!] (C)2001-2099 Comsenz Inc.
 *      This is NOT a freeware, use is subject to license terms
 *
 *      $Id: space_plugin.php 25246 2011-11-02 03:34:53Z zhangguosheng $
 */
if (!defined('IN_DISCUZ')) {
    exit('Access Denied');
}
$pluginkey = 'space_' . $_GET['op'];
$navtitle = $_G['setting']['plugins'][$pluginkey][$_GET['id']]['name'];
include pluginmodule($_GET['id'], $pluginkey);
include template('home/space_plugin');
<?php

/**
 *      [Discuz!] (C)2001-2099 Comsenz Inc.
 *      This is NOT a freeware, use is subject to license terms
 *
 *      $Id: modcp_plugin.php 6752 2010-03-25 08:47:54Z cnteacher $
 */
if (!defined('IN_DISCUZ') || !defined('IN_MODCP')) {
    exit('Access Denied');
}
$modtpl = $_G['gp_id'];
include pluginmodule($_G['gp_id'], 'modcp_' . $op);
Example #6
0
                    $sqlsrch = "WHERE title LIKE '%{$keyword}%' OR message LIKE '%{$keyword}%'";
                    break;
                case 'title':
                    $sqlsrch = "WHERE title LIKE '%{$keyword}%'";
                    break;
                case 'message':
                    $sqlsrch = "WHERE message LIKE '%{$keyword}%'";
                    break;
            }
            $keyword = dstripslashes($keyword);
            $faqlist = array();
            $query = DB::query("SELECT fpid, title, message FROM " . DB::table('forum_faq') . " {$sqlsrch} ORDER BY displayorder");
            while ($faq = DB::fetch($query)) {
                if (!empty($faq['fpid'])) {
                    $faq['title'] = preg_replace("/(?<=[\\s\"\\]>()]|[-ÿ]|^)(" . preg_quote($keyword, '/') . ")(([.,:;-?!()\\s\"<\\[]|[-ÿ]|\$))/siU", "<u><b><font color=\"#FF0000\">\\1</font></b></u>\\2", dstripslashes($faq['title']));
                    $faq['message'] = preg_replace("/(?<=[\\s\"\\]>()]|[-ÿ]|^)(" . preg_quote($keyword, '/') . ")(([.,:;-?!()\\s\"<\\[]|[-ÿ]|\$))/siU", "<u><b><font color=\"#FF0000\">\\1</font></b></u>\\2", dstripslashes($faq['message']));
                    $faqlist[] = $faq;
                }
            }
        } else {
            showmessage('faq_keywords_empty', 'misc.php?mod=faq');
        }
    }
} elseif ($_G['gp_action'] == 'plugin' && !empty($_G['gp_id'])) {
    $navtitle = $_G['setting']['plugins']['faq'][$_G['gp_id']]['name'];
    $navigation = '<em>&rsaquo;</em> ' . $_G['setting']['plugins']['faq'][$_G['gp_id']]['name'];
    include pluginmodule($_G['gp_id'], 'faq');
} else {
    $navtitle = lang('core', 'faq');
}
include template('common/faq');