dz论坛的签到插件无法安装,显示Discuz! Database Error1146,执行sql代码除DROP开MyISAM;尾语句怎么划分 10
<?phpif(!defined('IN_ADMINCP'))exit('AccessDenied');$sql=<<<EOFDROPTABLEIFEXISTS`cdb_...
<?php
if(!defined('IN_ADMINCP')) exit('Access Denied');
$sql = <<<EOF
DROP TABLE IF EXISTS `cdb_dsu_paulsign`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsign` (
`uid` int(10) unsigned NOT NULL,
`time` int(10) NOT NULL,
`days` int(5) NOT NULL DEFAULT '0',
`lasted` int(5) NOT NULL DEFAULT '0',
`mdays` int(5) NOT NULL DEFAULT '0',
`reward` int(12) NOT NULL DEFAULT '0',
`lastreward` int(12) NOT NULL DEFAULT '0',
`qdxq` varchar(5) NOT NULL,
`todaysay` varchar(100) NOT NULL,
PRIMARY KEY (`uid`),
KEY `time` (`time`)
) ENGINE=MyISAM;
DROP TABLE IF EXISTS `cdb_dsu_paulsignset`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsignset` (
`id` int(10) unsigned NOT NULL,
`todayq` int(10) NOT NULL DEFAULT '0',
`yesterdayq` int(10) NOT NULL DEFAULT '0',
`highestq` int(10) NOT NULL DEFAULT '0',
`qdtidnumber` int(10) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
INSERT INTO `cdb_dsu_paulsignset` (id, todayq, yesterdayq, highestq,
qdtidnumber) VALUES ('1', '0', '0', '0', '0');
DROP TABLE IF EXISTS `cdb_dsu_paulsignemot`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsignemot` (
`id` int(5) unsigned NOT NULL AUTO_INCREMENT,
`displayorder` tinyint(3) NOT NULL DEFAULT '0',
`qdxq` varchar(5) NOT NULL,
`count` int(6) NOT NULL DEFAULT '0',
`name` varchar(20) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
INSERT INTO `cdb_dsu_paulsignemot` (`id`, `displayorder`, `qdxq`,
`name`) VALUES
(1, 1, 'kx', '$installlang[mb_qb1]'),
(2, 2, 'ng', '$installlang[mb_qb2]'),
(3, 3, 'ym', '$installlang[mb_qb3]'),
(4, 4, 'wl', '$installlang[mb_qb4]'),
(5, 5, 'nu', '$installlang[mb_qb5]'),
(6, 6, 'ch', '$installlang[mb_qb6]'),
(7, 7, 'fd', '$installlang[mb_qb7]'),
(8, 8, 'yl', '$installlang[mb_qb8]'),
(9, 9, 'shuai', '$installlang[mb_qb9]');
EOF;
runquery($sql);
$cacheechos = array();
$cacheechokeys = array();
$queryc = DB::query("SELECT * FROM ".DB::table('dsu_paulsignemot')."
ORDER BY displayorder");
while($cacheecho = DB::fetch($queryc)) {
$cacheechos[$cacheecho['qdxq']] = $cacheecho;
$cacheechokeys[] = $cacheecho['qdxq'];
}
C::t('common_setting')->update('paulsign_emot', $cacheechos);
DB::query("ALTER TABLE ".DB::table('common_stat')." ADD paulsign int
(10) UNSIGNED NOT NULL DEFAULT '0'");
updatecache('setting');
$finish = TRUE;
?> 展开
if(!defined('IN_ADMINCP')) exit('Access Denied');
$sql = <<<EOF
DROP TABLE IF EXISTS `cdb_dsu_paulsign`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsign` (
`uid` int(10) unsigned NOT NULL,
`time` int(10) NOT NULL,
`days` int(5) NOT NULL DEFAULT '0',
`lasted` int(5) NOT NULL DEFAULT '0',
`mdays` int(5) NOT NULL DEFAULT '0',
`reward` int(12) NOT NULL DEFAULT '0',
`lastreward` int(12) NOT NULL DEFAULT '0',
`qdxq` varchar(5) NOT NULL,
`todaysay` varchar(100) NOT NULL,
PRIMARY KEY (`uid`),
KEY `time` (`time`)
) ENGINE=MyISAM;
DROP TABLE IF EXISTS `cdb_dsu_paulsignset`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsignset` (
`id` int(10) unsigned NOT NULL,
`todayq` int(10) NOT NULL DEFAULT '0',
`yesterdayq` int(10) NOT NULL DEFAULT '0',
`highestq` int(10) NOT NULL DEFAULT '0',
`qdtidnumber` int(10) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
INSERT INTO `cdb_dsu_paulsignset` (id, todayq, yesterdayq, highestq,
qdtidnumber) VALUES ('1', '0', '0', '0', '0');
DROP TABLE IF EXISTS `cdb_dsu_paulsignemot`;
CREATE TABLE IF NOT EXISTS `cdb_dsu_paulsignemot` (
`id` int(5) unsigned NOT NULL AUTO_INCREMENT,
`displayorder` tinyint(3) NOT NULL DEFAULT '0',
`qdxq` varchar(5) NOT NULL,
`count` int(6) NOT NULL DEFAULT '0',
`name` varchar(20) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
INSERT INTO `cdb_dsu_paulsignemot` (`id`, `displayorder`, `qdxq`,
`name`) VALUES
(1, 1, 'kx', '$installlang[mb_qb1]'),
(2, 2, 'ng', '$installlang[mb_qb2]'),
(3, 3, 'ym', '$installlang[mb_qb3]'),
(4, 4, 'wl', '$installlang[mb_qb4]'),
(5, 5, 'nu', '$installlang[mb_qb5]'),
(6, 6, 'ch', '$installlang[mb_qb6]'),
(7, 7, 'fd', '$installlang[mb_qb7]'),
(8, 8, 'yl', '$installlang[mb_qb8]'),
(9, 9, 'shuai', '$installlang[mb_qb9]');
EOF;
runquery($sql);
$cacheechos = array();
$cacheechokeys = array();
$queryc = DB::query("SELECT * FROM ".DB::table('dsu_paulsignemot')."
ORDER BY displayorder");
while($cacheecho = DB::fetch($queryc)) {
$cacheechos[$cacheecho['qdxq']] = $cacheecho;
$cacheechokeys[] = $cacheecho['qdxq'];
}
C::t('common_setting')->update('paulsign_emot', $cacheechos);
DB::query("ALTER TABLE ".DB::table('common_stat')." ADD paulsign int
(10) UNSIGNED NOT NULL DEFAULT '0'");
updatecache('setting');
$finish = TRUE;
?> 展开
1个回答
展开全部
方法/步骤
购买的Discuz x2.5模板或者插件是,系统会提示我们:对不起,您安装的不是正版应用,安装程序无法继续执行。这个是因为这个模板、插件是正版的,而discuz 社区在更新到2.0以上后,增加了对插件的版本检测,那名我们有没有办法解决呢?答案是很简单的。
方法一:/source/function/function_cloudaddons.php这个文件,然后打开,再找到cloudaddons_validator方法,删去或者注释掉cpmsg('cloudaddons_genuine_message', '', 'error', array('addonid' => $addonid));这句代码,这样就解决问题了。注释方法如下:function cloudaddons_validator($addonid) { $array = cloudaddons_getmd5($addonid); if(cloudaddons_open('&mod=app&ac=validator&addonid='.$addonid.($array !== false ? '&rid='.$array['RevisionID'].'&sn='.$array['SN'].'&rd='.$array['RevisionDateline'] : '')) === '0') { }}
方法二: 模板不能安装只要修改你模板文件夹名称就可以安装了,比如原来的模板是pengyouz,现在你任意修改比如修改为pengyouzz,然后在模板安装文件找到./template/pengyouz你把这个里面的pengyouz改为刚才你修改过的新名称pengyouzz,这样就可以了,还有就是需要修改模板名称链接,可以用Dreamweaver来批量修改。
购买的Discuz x2.5模板或者插件是,系统会提示我们:对不起,您安装的不是正版应用,安装程序无法继续执行。这个是因为这个模板、插件是正版的,而discuz 社区在更新到2.0以上后,增加了对插件的版本检测,那名我们有没有办法解决呢?答案是很简单的。
方法一:/source/function/function_cloudaddons.php这个文件,然后打开,再找到cloudaddons_validator方法,删去或者注释掉cpmsg('cloudaddons_genuine_message', '', 'error', array('addonid' => $addonid));这句代码,这样就解决问题了。注释方法如下:function cloudaddons_validator($addonid) { $array = cloudaddons_getmd5($addonid); if(cloudaddons_open('&mod=app&ac=validator&addonid='.$addonid.($array !== false ? '&rid='.$array['RevisionID'].'&sn='.$array['SN'].'&rd='.$array['RevisionDateline'] : '')) === '0') { }}
方法二: 模板不能安装只要修改你模板文件夹名称就可以安装了,比如原来的模板是pengyouz,现在你任意修改比如修改为pengyouzz,然后在模板安装文件找到./template/pengyouz你把这个里面的pengyouz改为刚才你修改过的新名称pengyouzz,这样就可以了,还有就是需要修改模板名称链接,可以用Dreamweaver来批量修改。
AiPPT
2024-09-19 广告
2024-09-19 广告
随着AI技术的飞速发展,如今市面上涌现了许多实用易操作的AI生成工具1、简介:AiPPT: 这款AI工具智能理解用户输入的主题,提供“AI智能生成”和“导入本地大纲”的选项,生成的PPT内容丰富多样,可自由编辑和添加元素,图表类型包括柱状图...
点击进入详情页
本回答由AiPPT提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询