第 1 頁 (共 1 頁)
[問題] 快速回覆功能PLUS進階版(已解決)
發表於 : 2004-12-31 18:07
由 wert
問題外掛:快速回覆功能PLUS進階版
參考連結:
1.
http://phpbb-tw.net/phpbb/viewtopic.php?t=14541
2.
http://phpbb-tw.net/phpbb/viewtopic.php?t=13009
3.
http://phpbb-tw.net/phpbb/viewtopic.php?t=14847
使用版本:phpBB 2.0.11
狀況描述:
小弟在加完參考連結1之後,又再加了參考連結2&3,結果是ok了,
但是在快速回覆中,當按下表情符號之後,出現以下訊息:
Notice: Undefined variable: mode in l:\easyphp1-7\www\phpbb2\quick_reply.php on line 29
Hacking attempt1
然後小弟打開quick_reply.php的檔案
查詢第29行代碼為:
代碼: 選擇全部
//
// BEGIN OUTPUT
//
$phpbb_root_path = "./";
if ( $mode == 'smilie' ) [color=red]<---這是第29行[/color]
{
define('IN_PHPBB', true);
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
include($phpbb_root_path . 'includes/functions_post.'.$phpEx);
generate_smilies('window', PAGE_POSTING);
exit;
}
if ( !defined('IN_PHPBB') )
{
die('Hacking attempt1');
}
$template->set_filenames(array(
'quick_reply_output' => 'quick_reply.tpl')
);
請問是我那邊出錯??
要如何修改??
請各位前輩指導一下
謝謝!!
發表於 : 2005-02-05 21:34
由 wert
真的無解嗎??
我自己有再去試過
發現了一個問題
也就是當我把第29行代碼
代碼: 選擇全部
if ( $mode == 'smilie' )
其中的二個等於拿掉一個,變成:
代碼: 選擇全部
if ( $mode = 'smilie' )
就出現全部的表情符號了
可是當我再轉回文章主題頁時
卻變成無法觀看文章了
出現了一個錯誤訊息:
Fatal error: Cannot redeclare class template in l:\easyphp1-7\www\phpbb2\includes\template.php on line 30
當我再把那個拿掉的 " = " 符號再加回去之後
又可以看到文章了
可是就又回到原本的問題去了....表情符號又出不來...不見了\r
只又見到那個錯誤的訊息\r
有哪位可以教教我解決嗎??
謝謝!!
發表於 : 2005-02-05 22:01
由 ~倉木麻衣~
試看看把第29行的$mode改成$HTTP_POST_VARS['mode']
也就是if ( $HTTP_POST_VARS['mode'] == 'smilie' )
發表於 : 2005-02-05 23:09
由 wert
~倉木麻衣~ 寫:試看看把第29行的$mode改成$HTTP_POST_VARS['mode']
也就是if ( $HTTP_POST_VARS['mode'] == 'smilie' )
謝謝回答
剛剛去修改測試一下
結果還是一樣不行
看來真的無解了
\n再繼續努力研究看看
也希望有哪位大大也能幫我解惑一下
謝謝!!
發表於 : 2005-02-05 23:31
由 ~倉木麻衣~
能給個網址、phpbb版本、快速回覆外掛的版本等基本資訊嗎?
還有能再詳述操作上遇到的問題嗎?
我剛試著安裝並測試~並沒有出現你提出的狀況
ps.我是由phpbbhacks網站下載的Advanced Quick Reply Mod~
版本為1.1.1
發表於 : 2005-02-06 00:16
由 小西
你安裝完不要額外修改應該就沒問題了
發表於 : 2005-02-06 02:35
由 wert
~倉木麻衣~ 寫:能給個網址、phpbb版本、快速回覆外掛的版本等基本資訊嗎?
還有能再詳述操作上遇到的問題嗎?
我剛試著安裝並測試~並沒有出現你提出的狀況
ps.我是由phpbbhacks網站下載的Advanced Quick Reply Mod~
版本為1.1.1
之前我是在我的NB裡學習架站
我已經放到我家裡的PC上
我沒有網址
只有IP位置(我是固定IP的)
我用的phpbb版本是2.0.11
快速回覆外掛的版本跟你一樣都是從phpbbhacks網站下載的Advanced Quick Reply Mod~版本也是1.1.1
倉木麻衣大大\r
我把我的IP位置用訊息傳給你
麻煩你幫我測試一下
謝謝!!
發表於 : 2005-02-06 02:53
由 wert
小西 寫:你安裝完不要額外修改應該就沒問題了
小西大大\r
我裝快速回覆都是照著他的去修改\r
沒有另外再修改什麼\r
他的quick_reply.php 跟 quick_reply.tpl 都沒動
只有中文的部分有翻譯(因為他是英文的沒有中文的)
我會再繼續努力的去試試看
發表於 : 2005-02-06 03:40
由 小西
wert 寫:小西大大\r
我裝快速回覆都是照著他的去修改\r
沒有另外再修改什麼\r
他的quick_reply.php 跟 quick_reply.tpl 都沒動
只有中文的部分有翻譯(因為他是英文的沒有中文的)
我會再繼續努力的去試試看
你是裝PLUS進階版還是普通的Advanced Quick Reply Mod?
發表於 : 2005-02-06 04:31
由 wert
小西 寫:wert 寫:小西大大\r
我裝快速回覆都是照著他的去修改\r
沒有另外再修改什麼\r
他的quick_reply.php 跟 quick_reply.tpl 都沒動
只有中文的部分有翻譯(因為他是英文的沒有中文的)
我會再繼續努力的去試試看
你是裝PLUS進階版還是普通的Advanced Quick Reply Mod?
應該是進階版的吧\r
我最先是裝竹貓版的快速回覆
後來又看到這個才又改裝這個
安裝的文件如下:
代碼: 選擇全部
#################################################################
## Mod Title: Advanced Quick Reply Mod
## Mod Author: RustyDragon <dev@RustyDragon.com> http://www.phpbbhacks.com
## Mod Version: 1.1.1
## Mod Description: This will allow users to use quick reply form
## which is placed below every topic.
## It will only display when user has the Reply access
## User have a option to quote the last message.
## A list of 24 smilies is shown below input area.
## Users can paste names of users just by clicking on it.
## Also they can select any text on a page and quote it to the input area.
##
## Last 3 options were absent in Quick Reply Mod with Quote on which
## this mod is based.
## Additional feature - uses of template for quick reply form.
## So you can change a look of the mod to whatever you want.
##
## Installation Level: Very Easy
## Installation Time: 4 Minutes
##
## Files To Edit: 3
## viewtopic.php,
## language/lang_english/lang_main.php
## templates/subSilver/viewtopic_body.tpl
##
## Included Files: quick_reply.php, quick_reply.tpl
#################################################################
##
## Author Note:
## If you want to have different number of smilies displayed find a line
## $max_smilies = 30;
## in a file quick_reply.php and replace 30 with whatever you want. Setting this variable to zero
## will disable smilies row.
##
## This MOD is based on Quick Reply Mod with Quote from Smartor <smartor_xp@hotmail.com>
##
## This mod will increase the size of your topic page by approx 7kb
## and execute one additional (but simple) SQL query for every page load.
##
## The Quick-Quote Feature was an idea from Nexialys (www.bebeabord.org)
##
## You should change all your templates and language pack
##
## Advanced Quick Reply Mod is Copyright ?RustyDragon, 2002
##
## Quick Reply Mod with Quote is Copyright ?Smartor, 2002
## updated to support phpbb 2.0.4 by danb00
##
## (Any changes to this MOD must retain these Copyright Notices)
#
#-----[ COPY ]------------------------------------------
#
copy quick_reply.php to /
copy quick_reply.tpl to templates/subSilver
#
#-----[ OPEN ]------------------------------------------
#
viewtopic.php
#
#-----[ FIND ]------------------------------------------
#
$template->pparse('body');
include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
#
#-----[ BEFORE, ADD ]------------------------------------
#
include($phpbb_root_path . 'quick_reply.'.$phpEx);
#
#-----[ OPEN ]------------------------------------------
#
lang/lang_chinese_traditional_taiwan/lang_main.php
#
#-----[ FIND ]------------------------------------------
#
//
// That's all Folks!
#
#-----[ BEFORE, ADD ]------------------------------------
#
// Advanced Quick Reply Mod
$lang['Quick_Reply'] = '快速回覆';
$lang['Quick_quote'] = '引用最後文章回覆';
$lang['Quick_add_smilies'] = '表情符號';
$lang['QuoteSelelected'] = '引用文章已選擇';
$lang['QuoteSelelectedEmpty'] = '請選擇頁面上的文字或是重試一次';
$lang['Quick_Reply_smilies'] = '所有';
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/viewtopic_body.tpl
#
#-----[ FIND ]------------------------------------------
#
{postrow.POSTER_NAME}
#
#-----[ REPLACE WITH ]------------------------------------
#
<a href="javascript:emoticon('{postrow.POSTER_NAME}, ')">{postrow.POSTER_NAME}</a>
#
#-----[ FIND ]------------------------------------------
#
<!-- END postrow -->
#
#-----[ AFTER, ADD ]------------------------------------
#
<tr align="center">
<td class="row1" colspan="2" >
{QUICKREPLY_OUTPUT}
</td>
</tr>
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------
#
#EoM
我只有將其中的語言部分改成中文的
其他都沒變動
發表於 : 2005-02-06 13:10
由 ~倉木麻衣~
那麼就把第29行改作
if ( $HTTP_GET_VARS['mode'] == 'smilie' )
試看看吧~
發表於 : 2005-02-06 15:38
由 wert
~倉木麻衣~ 寫:那麼就把第29行改作
if ( $HTTP_GET_VARS['mode'] == 'smilie' )
試看看吧~
倉木麻衣大大\r
謝謝指導
剛剛照你的說法去改來試試看
結果原本出現的訊息為:
Notice: Undefined variable: mode in l:\easyphp1-7\www\phpbb2\quick_reply.php on line 29
Hacking attempt1
改完之後出現的訊息為:
Hacking attempt1
<---只剩下這行
Notice: Undefined variable: mode in l:\easyphp1-7\www\phpbb2\quick_reply.php on line 29
<---這行消失不見了
不知你是否有進來我的站看過了呢??
發表於 : 2005-02-06 16:01
由 ~倉木麻衣~
嗯~有去看過了~
正在研究中
發表於 : 2005-02-06 20:17
由 wert
按錯鈕~~自爆~~

發表於 : 2005-02-06 20:18
由 wert
問題終於解決了
感謝倉木麻衣大大在放假期間還大力幫小弟解決問題
衷心感激.......