1 頁 (共 1 頁)

[問題] 2.0.11升級到 2.0.12 的 template.php

發表於 : 2005-02-24 15:16
sh85216s
升級的 patch 有一段關於 includes/template.php 的修正如下:
------------------------------------------------------------------------------------
找到\r

代碼: 選擇全部

             $filename = [color=red]phpbb_realpath[/color]($this->root . '/' . $filename); 
置換為\r

代碼: 選擇全部

             $filename = ($rp_filename = [color=red]phpbb_realpath[/color]($this->root . '/' . $filename)) ? $rp_filename : $filename;
------------------------------------------------------------------------------------

但我的 template.php 中並無類似的字串,不知如何修改?請大家幫忙一下!

由於檔案很大,只貼出可能相關的程式碼.

我的 template.php 相關的程式碼如下:

代碼: 選擇全部

                        // search if this file is part of a sub-template
                        $sub_tpl_file = '';
                        $sub_css_file = '';
                        $sub_img_file = '';
                        $sub_img_path = '';
                        $template_path = 'templates/';
                        $template_name = substr( $this->root, strpos($this->root, $template_path) + strlen($template_path) );
                        $real_root = $this->root;
                        if ( $board_config['version'] > '.0.5' )
                        {
                                $real_root = @[color=red]phpbb_realpath[/color]($this->root);
                        }
                        if (substr($filename, 0, 1) != '/')
                        {
                                $found = false;
                                $num_fids = count($fids);
                                for ($i = 0; !$found && ($i < $num_fids); $i++)
                                {
                                        $key = $fids[$i];
另一段可能相關的程式碼如下:

代碼: 選擇全部

                // Check if sub_templates are defined for this theme
                if ( $board_config['version'] > '.0.5' )
                {
                        $sub_templates_cfg = @[color=red]phpbb_realpath[/color]($this->root . '/sub_templates.cfg');
                }
                else
                {
                        $sub_templates_cfg = $this->root . '/sub_templates.cfg';
                }
                @include($sub_templates_cfg);
                if ( isset($sub_templates) )
                {
請高手幫忙一下,感謝...

發表於 : 2005-02-24 15:26
赤兔
你若有裝 eXtreme Styles mod 就不用改\r
http://phpbb-tw.net/phpbb/viewtopic.php?p=186398#186398

發表於 : 2005-02-24 15:34
sh85216s
感謝...........................