[問題] 關於簡易子版面v1.0 > 子版面在首頁顯示位置錯誤...

網站架設,免費空間申請,架站技術交流區
Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

[問題] 關於簡易子版面v1.0 > 子版面在首頁顯示位置錯誤...

文章Movue » 2005-07-05 3:40 am

問題外掛: 簡易子版面v1.0
使用版本:phpBB 2.0.16
網站位置:http://xphp.biz/movue/phpbb/index.php

參考連結:
簡易子版面v1.0安裝方式
http://phpbb-tw.net/phpbb/viewtopic.php?t=33019&highlight=%C2%B2%A9%F6%A4l%AA%A9%AD%B1



我的問題描述:

1. 
我的子版面在首頁顯示成...這樣樣子?!
圖檔

但是...
圖檔

不過,我在後台控制時...卻是有顯示"子版面"的字樣,這樣應該是正常的狀況吧?
圖檔

在後台編輯的時候,可以新增.移動子版面,而這個拉頁也沒有錯吧?!
圖檔

但是,從網站看來,卻有點小問題...??
為什麼會出現問號呢?
而且子版面(我算它為第三層)和第二層的版面卻是並排的...?!
圖檔


關於這個問題,我有參考過別人的發問>
http://phpbb-tw.net/phpbb/viewtopic.php?t=36178&highlight=%C2%B2%A9%F6%A4l%AA%A9%AD%B1+%AD%BA%AD%B6

我的結論是:
我沒有安裝其他風格~也沒有安裝過其他外掛~論壇是全新的~






2.

請看...這個畫面時是正常的...
圖檔

點文進去之後...就變成...中間的層次(第二層)不見了...?!
圖檔

發文的時候...中間的層次(第二層)也是不見了...?!
圖檔


關於這個問題,我有參考過別人的發問>
http://bbs.2233.idv.tw/viewtopic.php?t=22014


我的結論是:
我有相同的問題!!
但是 ETERNAL 大大 所說的那一段,我確定都有改了!!


ETERNAL 寫:問題一,
---------------------------------------------------------

打開 viewtopic_body.tpl

找到=================
-> <a class="nav" href="{U_VIEW_FORUM}">{FORUM_NAME}</a>
取代為===============
{FORUM_PATH}
---------------------------------------------------------

這段你有改嗎




最後,我的狀況補充:

我的論壇是全新的,還沒有裝任何的外掛和風格唷~
第一個裝的外掛就是這個簡易子版面v1.0了!!

不知道是哪裡出了錯,參考其他人的問題之後,我也比對過一些有可能錯誤的檔案,可是都沒有問題啊,確實完整照安裝說明修改了~

比對過的檔案有:
admin_forums.php
index_body.tpl


懇請ETERNAL大大.還有厲害的高手們為小女子解惑吧...!!
拜託了!!
感激不盡!!




ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-05 3:59 pm

問題一,你可能是index.php沒改好,需要檢查一下你的index.php

問題二,
可能是你
代碼: 選擇全部
打開 \includes\functions.php

找到=================
function make_jumpbox($action, $match_forum_id = 0)
{
....................
....................
....................
}

將整個 function make_jumpbox($action , $match_forum_id = 0) 取代為=========


沒改到

以及

代碼: 選擇全部
---------------------------------------------------------

打開 \templates\subSilver\jumpbox.tpl

找到====================================
<form method="get" name="jumpbox" action="{S_JUMPBOX_ACTION}" onSubmit="if(document.jumpbox.f.value == -1){return false;}"><table cellspacing="0" cellpadding="0" border="0">
前面加上=================================
<script language="JavaScript">
function add_select(val,na,s,sort)
{
   var temp="";
   if(sort>0)
   {
      na="→ "+na
   }
   for(var i=0;i<sort;i++)
   {
      temp+=" ";
   }
   document.write('<option value="'+val+'" '+s+'>'+temp+na+'</option>');
}
</script>
找到======================================
{S_JUMPBOX_SELECT}
取代為=====================================
<script language="JavaScript">{S_JUMPBOX_SELECT}</script>
---------------------------------------------------------


也沒改到

問題三,
可能是你viewtopic.php

代碼: 選擇全部
打開 viewtopic.php

找到==================================

$forum_id = intval($forum_topic_data['forum_id']);

後面加上==================================

//forum_sub start
$forum_path=forum_path($forum_topic_data,$forum_id);
//forum_sub end

找到==================================

'FORUM_ID' => $forum_id,

後面加上==================================

'FORUM_PATH' => $forum_path,

---------------------------------------------------------


這段沒改到



Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-05 8:29 pm

謝謝ETERNAL大大!!

問題一 解決了~
我檢查過了 index.php

發現有一段
之前我在安裝方法的部分,照著這篇文章
的"修改一"

御津闇慈 寫:修改一
INDEX顯示子分區成這樣
打開index.php
尋找
代碼:

代碼: 選擇全部
$forum_sub_list="子版面 : ".$forum_sub_list;



替換成
代碼:
代碼: 選擇全部
$forum_sub_list='<fieldset><legend>子版面</legend><table width="100%" cellpadding="0" cellspacing="0" border="0"> '.$forum_sub_list.'</table></fieldset>';




結果可能是我沒改好,改回去之後,首頁就正常了~
後來我又重新複製再貼一次代碼,結果就成功的顯示出來了...==|||


謝謝ETERNAL大大提醒~
我真是笨哪...唉唉...



至於問題二和問題三還是沒有解決耶~
我都照著 ETERNAL大大所說的檔案去檢查過了~
那幾段語法我確定都有改到,也比對過有沒有漏掉一兩個字元,都查過了,沒有錯誤的地方.

現在剩下的就是問題二和問題三:
問題二.拉頁選單的部分,字首會出現問號"?"
問題三.看文.發文時,層次顯示不完整

這到底該怎麼辦呢... :roll:

讓ETERNAL大大費心了,謝謝您喔!!




ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-05 10:09 pm

問題三

代碼: 選擇全部
打開 viewtopic.php

找到==================================

$forum_id = intval($forum_topic_data['forum_id']);

後面加上==================================

//forum_sub start
$forum_path=forum_path($forum_topic_data,$forum_id);
//forum_sub end

找到==================================

'FORUM_ID' => $forum_id,

後面加上==================================

'FORUM_PATH' => $forum_path,


代碼: 選擇全部
打開 \templates\subSilver\viewtopic_body.tpl

找到=================
 -> <a class="nav" href="{U_VIEW_FORUM}">{FORUM_NAME}</a>
取代為===============
 {FORUM_PATH}


代碼: 選擇全部
打開 posting.php

找到=================
   $forum_name = $post_info['forum_name'];
後面加上===============
   $forum_path=forum_path($post_info,$forum_id);
找到=================
   'L_POST_SUBJECT' => $lang['Post_subject'],
後面加上===============
   'FORUM_PATH' => $forum_path,


代碼: 選擇全部
打開 \templates\subSilver\posting_body.tpl

找到=================
-> <a href="{U_VIEW_FORUM}" class="nav">{FORUM_NAME}</a>
取代為===============
 {FORUM_PATH}





ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-05 10:17 pm

問題二

代碼: 選擇全部
打開 \templates\subSilver\jumpbox.tpl

找到====================================
<form method="get" name="jumpbox" action="{S_JUMPBOX_ACTION}" onSubmit="if(document.jumpbox.f.value == -1){return false;}"><table cellspacing="0" cellpadding="0" border="0">
前面加上=================================
<script language="JavaScript">
function add_select(val,na,s,sort)
{
   var temp="";
   if(sort>0)
   {
      na="→ "+na
   }
   for(var i=0;i<sort;i++)
   {
      temp+=" ";
   }
   document.write('<option value="'+val+'" '+s+'>'+temp+na+'</option>');
}
</script>


可能你自己改過下面這段
代碼: 選擇全部
   if(sort>0)
   {
      na="→ "+na
   }
   for(var i=0;i<sort;i++)
   {
      temp+=" ";
   }




Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-06 2:54 pm

感謝ETERNAL大大!!^^

問題二,已經解決~
不過,我並沒有動過那一段代碼才是...@@怪怪~


問題三,解決了一半...
現在的狀況是,原本的"發表主題""回覆文章"時看不到完整版面路徑,現在已經可以看到了!!

但是,觀看子版面的"文章內容"時,版面路徑卻仍然少了中間那一層~

根據您提供的解決方式,修改的代碼部分,

代碼: 選擇全部
打開 viewtopic.php

代碼: 選擇全部
打開 \templates\subSilver\viewtopic_body.tpl


以上這兩段,我開啟檔案的時候,都已經有改好了,沒有漏掉的地方~
為了確認,我也重新再複製.貼上.修改~
可是,問題還是沒有解決耶... :roll:




ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-06 5:08 pm


viewtopic.php
viewtopic_body.tpl

貼出來讓我看看吧


水色論壇 http://www.et99.net
簡恩峻分享

Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-06 10:23 pm

真是慚愧...
這麼勞煩ETERNAL大大您~
真的很不好意思...
感激不盡吶!!


我的 viewtopic.php

我的 viewtopic_body.tpl 如下:

代碼: 選擇全部
<table width="100%" cellspacing="2" cellpadding="2" border="0">
  <tr>
   <td align="left" valign="bottom" colspan="2"><a class="maintitle" href="{U_VIEW_TOPIC}">{TOPIC_TITLE}</a><br />
     <span class="gensmall"><b>{PAGINATION}</b><br />
     &nbsp; </span></td>
  </tr>
</table>

<table width="100%" cellspacing="2" cellpadding="2" border="0">
  <tr>
   <td align="left" valign="bottom" nowrap="nowrap"><span class="nav"><a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" alt="{L_POST_NEW_TOPIC}" align="middle" /></a>&nbsp;&nbsp;&nbsp;<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" alt="{L_POST_REPLY_TOPIC}" align="middle" /></a></span></td>
   <td align="left" valign="middle" width="100%"><span class="nav">&nbsp;&nbsp;&nbsp;<a href="{U_INDEX}" class="nav">{L_INDEX}</a>
     {FORUM_PATH}</span></td>
  </tr>
</table>

<table class="forumline" width="100%" cellspacing="1" cellpadding="3" border="0">
   <tr align="right">
      <td class="catHead" colspan="2" height="28"><span class="nav"><a href="{U_VIEW_OLDER_TOPIC}" class="nav">{L_VIEW_PREVIOUS_TOPIC}</a> :: <a href="{U_VIEW_NEWER_TOPIC}" class="nav">{L_VIEW_NEXT_TOPIC}</a> &nbsp;</span></td>
   </tr>
   {POLL_DISPLAY}
   <tr>
      <th class="thLeft" width="150" height="26" nowrap="nowrap">{L_AUTHOR}</th>
      <th class="thRight" nowrap="nowrap">{L_MESSAGE}</th>
   </tr>
   <!-- BEGIN postrow -->
   <tr>
      <td width="150" align="left" valign="top" class="{postrow.ROW_CLASS}"><span class="name"><a name="{postrow.U_POST_ID}"></a><b>{postrow.POSTER_NAME}</b></span><br /><span class="postdetails">{postrow.POSTER_RANK}<br />{postrow.RANK_IMAGE}{postrow.POSTER_AVATAR}<br /><br />{postrow.POSTER_JOINED}<br />{postrow.POSTER_POSTS}<br />{postrow.POSTER_FROM}</span><br /></td>
      <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
         <tr>
            <td width="100%"><a href="{postrow.U_MINI_POST}"><img src="{postrow.MINI_POST_IMG}" width="12" height="9" alt="{postrow.L_MINI_POST_ALT}" title="{postrow.L_MINI_POST_ALT}" border="0" /></a><span class="postdetails">{L_POSTED}: {postrow.POST_DATE}<span class="gen">&nbsp;</span>&nbsp; &nbsp;{L_POST_SUBJECT}: {postrow.POST_SUBJECT}</span></td>
            <td valign="top" nowrap="nowrap">{postrow.QUOTE_IMG} {postrow.EDIT_IMG} {postrow.DELETE_IMG} {postrow.IP_IMG}</td>
         </tr>
         <tr>
            <td colspan="2"><hr /></td>
         </tr>
         <tr>
            <td colspan="2"><span class="postbody">{postrow.MESSAGE}{postrow.SIGNATURE}</span><span class="gensmall">{postrow.EDITED_MESSAGE}</span></td>
         </tr>
      </table></td>
   </tr>
   <tr>
      <td class="{postrow.ROW_CLASS}" width="150" align="left" valign="middle"><span class="nav"><a href="#top" class="nav">{L_BACK_TO_TOP}</a></span></td>
      <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="bottom" nowrap="nowrap"><table cellspacing="0" cellpadding="0" border="0" height="18" width="18">
         <tr>
            <td valign="middle" nowrap="nowrap">{postrow.PROFILE_IMG} {postrow.PM_IMG} {postrow.EMAIL_IMG} {postrow.WWW_IMG} {postrow.AIM_IMG} {postrow.YIM_IMG} {postrow.MSN_IMG}<script language="JavaScript" type="text/javascript"><!--

   if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 )
      document.write(' {postrow.ICQ_IMG}');
   else
      document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute">{postrow.ICQ_IMG}</div><div style="position:absolute;left:3px;top:-1px">{postrow.ICQ_STATUS_IMG}</div></div>');
            
            //--></script><noscript>{postrow.ICQ_IMG}</noscript></td>
         </tr>
      </table></td>
   </tr>
   <tr>
      <td class="spaceRow" colspan="2" height="1"><img src="templates/subSilver/images/spacer.gif" alt="" width="1" height="1" /></td>
   </tr>
   <!-- END postrow -->
   <tr align="center">
      <td class="catBottom" colspan="2" height="28"><table cellspacing="0" cellpadding="0" border="0">
         <tr><form method="post" action="{S_POST_DAYS_ACTION}">
            <td align="center"><span class="gensmall">{L_DISPLAY_POSTS}: {S_SELECT_POST_DAYS}&nbsp;{S_SELECT_POST_ORDER}&nbsp;<input type="submit" value="{L_GO}" class="liteoption" name="submit" /></span></td>
         </form></tr>
      </table></td>
   </tr>
</table>

<table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">
  <tr>
   <td align="left" valign="middle" nowrap="nowrap"><span class="nav"><a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" alt="{L_POST_NEW_TOPIC}" align="middle" /></a>&nbsp;&nbsp;&nbsp;<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" alt="{L_POST_REPLY_TOPIC}" align="middle" /></a></span></td>
   <td align="left" valign="middle" width="100%"><span class="nav">&nbsp;&nbsp;&nbsp;<a href="{U_INDEX}" class="nav">{L_INDEX}</a>
     {FORUM_PATH}</span></td>
   <td align="right" valign="top" nowrap="nowrap"><span class="gensmall">{S_TIMEZONE}</span><br /><span class="nav">{PAGINATION}</span>
     </td>
  </tr>
  <tr>
   <td align="left" colspan="3"><span class="nav">{PAGE_NUMBER}</span></td>
  </tr>
</table>

<table width="100%" cellspacing="2" border="0" align="center">
  <tr>
   <td width="40%" valign="top" nowrap="nowrap" align="left"><span class="gensmall">{S_WATCH_TOPIC}</span><br />
     &nbsp;<br />
     {S_TOPIC_ADMIN}</td>
   <td align="right" valign="top" nowrap="nowrap">{JUMPBOX}<span class="gensmall">{S_AUTH_LIST}</span></td>
  </tr>
</table>





ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-06 10:49 pm

我看是沒問題
你確定你有上傳,以及有沒有錯誤訊息


水色論壇 http://www.et99.net
簡恩峻分享

Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-07 9:17 am

我確定有上傳.無誤~
(因為檔案是我從空間上抓下來的,也就是我最新的上傳的版本~
所以絕對確定這個檔案是上傳在空間中的~)

另外,沒有顯示錯誤訊息就是了~


我想還是算了,反正是小問題,就不必這麼大費周章了...
這樣一直勞煩您,真的很不好意思... :roll:
也許以後就會有解決的辦法說不定~ :wink:
不過,現在這樣(這個小問題)也沒什麼太大的影響吧~ :roll:

謝謝ETERNAL大大不閒麻煩的解決問題~ :D
謝謝唷!!

唉唉,我真是太笨了... :oops:




ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-07 9:57 am

方便的話
把你網站的帳號密碼給我,我去幫你看吧


水色論壇 http://www.et99.net
簡恩峻分享

Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-07 9:36 pm

有勞ETERNAL大大了~
在下已經將網站的帳密PM給您嚕~
請查收~

感謝大大的仗義相助~^^



Movue
 
文章: 8
註冊時間: 2005-07-05 2:06 am

文章Movue » 2005-07-07 11:12 pm

最近再測試了一下,
結果又發現了一點小問題...
不知道這些是不是正常的狀況...@@

分區>版面>子版面1>子版面2>

就是 當子版面開到 "子版面2" 之後,

發現:

1.進入"版面"觀看時,只看見有列出"子版面1",但是卻沒有列出"子版面1"的附屬子版面(也就是"子版面2")~ 完全沒看到~

2.在 " 前往--GO " 的選單拉頁中,也看不到"子版面2"的部分!? 全部都沒顯示出來~

3.瀏覽"子版面2"的文章內容時,也是沒有顯示完整路徑~
顯示成: 分區>子版面2

啊~~~天哪...
我的問題好多喔...
是我哪邊做錯了嗎?
可是我記得明明有很仔細的照著安裝方式修改啊...
怎麼這樣呢... :roll:




ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-10 4:28 pm

1.這問題沒有做,只有首頁才有這個功能
2.這是bug,直到現在才被你發現
解決方式

在includes/functions.php裡面

尋找
代碼: 選擇全部
$forum_sub2[$row['forum_sub']]=$row[forum_id];
改成
代碼: 選擇全部
$forum_sub2[$row['forum_sub']][]=$row[forum_id];


尋找
代碼: 選擇全部
         if ( count($forum_sub[$forum_data[$cat_id][$j][forum_id]]) > 0 )
         {
            $sub_list.= implode(' ', $forum_sub[$forum_data[$cat_id][$j][forum_id]]);
            $sub_list.=sub_search($forum_sub2[$forum_data[$cat_id][$j][forum_id]],$forum_sub,$forum_sub2);
         }


替換成

代碼: 選擇全部
      if ( count($forum_sub[$forum_data[$cat_id][$j][forum_id]]) > 0 )
      {
         for($jj=0;$jj<count($forum_sub[$forum_data[$cat_id][$j][forum_id]]);$jj++)
         {
            $sub_list.= $forum_sub[$forum_data[$cat_id][$j][forum_id]][$jj];
            $sub_list.=sub_search($forum_sub2[$forum_data[$cat_id][$j][forum_id]][$jj],$forum_sub,$forum_sub2);
         }
      }



尋找

代碼: 選擇全部
function sub_search($id,$forum_sub,$forum_sub2)
{
   if ( count($forum_sub[$id]) > 0 )
   {
      $list= implode(' ', $forum_sub[$id]);
      $list.=sub_search($forum_sub2[$id],$forum_sub,$forum_sub2);
   }
   return $list;
}


替換成

代碼: 選擇全部
function sub_search($id,$forum_sub,$forum_sub2)
{
   if ( count($forum_sub[$id]) > 0 )
   {
      $list="";
      for($jj=0;$jj<count($forum_sub[$id]);$jj++)
      {
         $list.= $forum_sub[$id][$jj];
         $list.=sub_search($forum_sub2[$id][$jj],$forum_sub,$forum_sub2);
      }
   }
   return $list;
}


打開admin/admin_forums.php

尋找
代碼: 選擇全部
$forum_sub2[$row['forum_sub']]=$row[forum_id];


改成
代碼: 選擇全部
$forum_sub2[$row['forum_sub']][]=$row[forum_id];



尋找
代碼: 選擇全部
         if ( count($forum_sub[$forum_data[$cat_id][$j][forum_id]]) > 0 )
         {
            $sub_list.= implode(' ', $forum_sub[$forum_data[$cat_id][$j][forum_id]]);
            $sub_list.=sub_search($forum_sub2[$forum_data[$cat_id][$j][forum_id]],$forum_sub,$forum_sub2);
         }


替換成
代碼: 選擇全部
         if ( count($forum_sub[$forum_data[$cat_id][$j][forum_id]]) > 0 )
         {
            for($jj=0;$jj<count($forum_sub[$forum_data[$cat_id][$j][forum_id]]);$jj++)
            {
               $sub_list.= $forum_sub[$forum_data[$cat_id][$j][forum_id]][$jj];
               $sub_list.=sub_search($forum_sub2[$forum_data[$cat_id][$j][forum_id]][$jj],$forum_sub,$forum_sub2);
            }
         }



最後由 ETERNAL 於 2005-07-10 5:45 pm 編輯,總共編輯了 1 次。


ETERNAL
 
文章: 2937
註冊時間: 2003-12-03 11:08 pm
性別: 男生

文章ETERNAL » 2005-07-10 4:29 pm

第三個問題
我不是幫你改好了嗎?


水色論壇 http://www.et99.net
簡恩峻分享

下一頁

回到 架站討論

誰在線上

正在瀏覽這個版面的使用者:沒有註冊會員 和 12 位訪客