PHP Nuke Nederland
 
•   Home  •  Downloads  •  Your Account  •  Forums  •
PHP-Nuke Nederland: Forums

PHP-Nuke Nederland :: View topic - [FIX] Handmatig upgraden van 2.0.13 -> 2.0.14
 Forum FAQ  •   Search   •  Memberlist  •  Usergroups   •  Register   •    •  Profile  •  Log in to check your private messages  •  Log in

 
Post new topicThis topic is locked: you cannot edit posts or make replies.
View previous topic Log in to check your private messages View next topic
Author Message
BlueLion
Administrator
Administrator


Joined: Aug 21, 2004
Posts: 2834

PostPosted: Sat 16 Apr 2005 20:19 Reply with quoteBack to top

These are the Changes from phpBB 2.0.13 to phpBB 2.0.14 summed up into a little Mod. This might be very helpful if you want to update your Board and have installed a bunch of Mods. Then it's normally easier to apply the Code Changes than to install all Mods again.

When you find a 'AFTER, ADD'-Statement, the Code have to be added after the last line quoted in the 'FIND'-Statement.
When you find a 'BEFORE, ADD'-Statement, the Code have to be added before the first line quoted in the 'FIND'-Statement.
When you find a 'REPLACE WITH'-Statement, the Code quoted in the 'FIND'-Statement have to be replaced completely with the quoted Code in the 'REPLACE WITH'-Statement.

After you have finished this tutorial, you have to upload the install/update_to_latest.php file, execute it and then delete it from your webspace.


Furthermore, please remove the file db/oracle.php from your webspace.

  • admin/admin_styles.php



  1. FIND - Line 78
    Code:


             include($phpbb_root_path. "templates/" . $install_to . "/theme_info.cfg");


    REPLACE WITH
    Code:


             include($phpbb_root_path. "templates/" . basename($install_to) . "/theme_info.cfg");



  2. FIND - Line 742
    Code:


             $fp = @fopen($phpbb_root_path . 'templates/' . $template_name . '/theme_info.cfg', 'w');


    REPLACE WITH
    Code:


             $fp = @fopen($phpbb_root_path . 'templates/' . basename($template_name) . '/theme_info.cfg', 'w');



  • admin/page_header_admin.php



  1. FIND - Line 38
    Code:


       $useragent = (isset($_SERVER["HTTP_USER_AGENT"]) ) ? $_SERVER["HTTP_USER_AGENT"] : $HTTP_USER_AGENT;


    REPLACE WITH
    Code:


       $useragent = (isset($HTTP_SERVER_VARS['HTTP_USER_AGENT'])) ? $HTTP_SERVER_VARS['HTTP_USER_AGENT'] : getenv('HTTP_USER_AGENT');



  • admin/page_footer_admin.php



  1. FIND - Line 36
    Code:


       'PHPBB_VERSION' => '2' . $board_config['version'],


    REPLACE WITH
    Code:


       'PHPBB_VERSION' => ($userdata['user_level'] == ADMIN && $userdata['user_id'] != ANONYMOUS) ? '2' . $board_config['version'] : '',



  • db/postgres7.php



  1. FIND - Line 125
    Code:


             $query = preg_replace("/LIMIT ([0-9]+),([ 0-9]+)/", "LIMIT \\2 OFFSET \\1", $query);


    AFTER, ADD
    Code:


             $query = preg_replace('#(.*WHERE.*)(username|user_email|ban_email) = \'(.*)\'#ise', "\"\\1LOWER(\\2) = '\" . strtolower('\\3') . \"'\"", $query);



  • includes/page_header.php



  1. FIND - Line 38
    Code:


       $useragent = (isset($_SERVER["HTTP_USER_AGENT"]) ) ? $_SERVER["HTTP_USER_AGENT"] : $HTTP_USER_AGENT;


    REPLACE WITH
    Code:


       $useragent = (isset($HTTP_SERVER_VARS['HTTP_USER_AGENT'])) ? $HTTP_SERVER_VARS['HTTP_USER_AGENT'] : getenv('HTTP_USER_AGENT');



  2. FIND - Line 469
    Code:


    if (!empty($_SERVER['SERVER_SOFTWARE']) && strstr($_SERVER['SERVER_SOFTWARE'], 'Apache/2'))


    REPLACE WITH
    Code:


    if (!empty($HTTP_SERVER_VARS['SERVER_SOFTWARE']) && strstr($HTTP_SERVER_VARS['SERVER_SOFTWARE'], 'Apache/2'))



  • includes/sessions.php



  1. FIND - Line 53
    Code:


          $session_id = '';
       }



    AFTER, ADD
    Code:


       $page_id = (int) $page_id;




  2. FIND - Line 92
    Code:


                   // No match; don't login, set as anonymous user
                   $login = 0;
                   $enable_autologin = 0;
                   $user_id = $userdata['user_id'] = ANONYMOUS;


    AFTER, ADD
    Code:


                
                   $sql = 'SELECT * FROM ' . USERS_TABLE . ' WHERE user_id = ' . ANONYMOUS;
                   $result = $db->sql_query($sql);
                   $userdata = $db->sql_fetchrow($result);
                   $db->sql_freeresult($result);



  3. FIND - Line 105
    Code:


                // Autologin is not set. Don't login, set as anonymous user
                $login = 0;
                $enable_autologin = 0;
                $user_id = $userdata['user_id'] = ANONYMOUS;


    AFTER, ADD
    Code:



                $sql = 'SELECT * FROM ' . USERS_TABLE . ' WHERE user_id = ' . ANONYMOUS;
                $result = $db->sql_query($sql);
                $userdata = $db->sql_fetchrow($result);
                $db->sql_freeresult($result);



  4. FIND - Line 244
    Code:


       //
       // Does a session exist?
       //


    BEFORE, ADD
    Code:


       $thispage_id = (int) $thispage_id;




  • modcp.php



  1. FIND - Line 130
    Code:


          message_die(GENERAL_MESSAGE, 'Topic_post_not_exist');
       }
       $topic_row = $db->sql_fetchrow($result);



    AFTER, ADD
    Code:


       if (!$topic_row)
       {
          message_die(GENERAL_MESSAGE, 'Topic_post_not_exist');
       }




  2. FIND - Line 150
    Code:


          message_die(GENERAL_MESSAGE, 'Forum_not_exist');
       }
       $topic_row = $db->sql_fetchrow($result);


    AFTER, ADD
    Code:



       if (!$topic_row)
       {
          message_die(GENERAL_MESSAGE, 'Forum_not_exist');
       }



  • privmsg.php



  1. FIND - Line 566
    Code:


       if ( !$board_config['allow_html'] )
        {
          if ( $user_sig != '' && $privmsg['privmsgs_enable_sig'] && $userdata['user_allowhtml'] )


    REPLACE WITH
    Code:


       if ( !$board_config['allow_html'] || !$userdata['user_allowhtml'])
       {
          if ( $user_sig != '')



  2. FIND - Line 1531
    Code:


          if ( !$html_on )
          {
             if ( $user_sig != '' || !$userdata['user_allowhtml'] )


    REPLACE WITH
    Code:


          if ( !$html_on || !$board_config['allow_html'] || !$userdata['user_allowhtml'] )
          {
             if ( $user_sig != '' )



  • search.php



  1. FIND - Line 200
    Code:


                $search_author = str_replace('*', '%', trim($search_author));


    BEFORE, ADD
    Code:


                if (preg_match('#^[\*%]+$#', trim($search_author)) || preg_match('#^[^\*]{1,2}$#', str_replace(array('*', '%'), '', trim($search_author))))
                {
                   $search_author = '';
                }




  2. FIND - Line 269
    Code:



             for($i = 0; $i < count($split_search); $i++)
             {


    AFTER, ADD
    Code:


                if (preg_match('#^[\*%]+$#', trim($split_search[$i])) || preg_match('#^[^\*]{1,2}$#', str_replace(array('*', '%'), '', trim($split_search[$i]))))
                {
                   $split_search[$i] = '';
                   continue;
                }




  3. FIND - Line 416
    Code:


          // Author name search
          //
          if ( $search_author != '' )
          {


    AFTER, ADD
    Code:


              if (preg_match('#^[\*%]+$#', trim($search_author)) || preg_match('#^[^\*]{1,2}$#', str_replace(array('*', '%'), '', trim($search_author))))
             {
                $search_author = '';
             }




  • viewtopic.php



  1. FIND - Line 1052
    Code:


       if ( !$board_config['allow_html'] )
       {
          if ( $user_sig != '' && $userdata['user_allowhtml'] )


    REPLACE WITH
    Code:


       if ( !$board_config['allow_html'] || !$userdata['user_allowhtml'])
       {
          if ( $user_sig != '' )



  2. FIND - Line 1122
    Code:


             $user_sig = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $user_sig . '<'), 1, -1));
          }

          $message = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $message . '<'), 1, -1));


    REPLACE WITH
    Code:


             $user_sig = str_replace('\"', '"', substr(@preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "@preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $user_sig . '<'), 1, -1));
          }

          $message = str_replace('\"', '"', substr(@preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "@preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $message . '<'), 1, -1));




Last edited by BlueLion on Sun 08 May 2005 6:05; edited 1 time in total
View user's profileSend private messageSend e-mailVisit poster's website
BlueLion
Administrator
Administrator


Joined: Aug 21, 2004
Posts: 2834

PostPosted: Sat 16 Apr 2005 20:23 Reply with quoteBack to top

FIX
View user's profileSend private messageSend e-mailVisit poster's website
Display posts from previous:      
 Donaties   Adverteren 
Wilt u het forum steunen, dan kunt u nu eenvoudig doneren met PayPal.
Post new topicThis topic is locked: you cannot edit posts or make replies.
View previous topic Log in to check your private messages View next topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2001, 2005 phpBB Group

Web site powered by PHP-Nuke

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © 2004-2008 by BlueLion.
SEO enhanced with the Sitemapper script
You can syndicate our news using the file backend.php or ultramode.txt
Powered by PHP Powered by MySQL Apache Webserver Valid robots.txt
PHP-Nuke Copyright © 2004 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.
Pagina rendering: 0.11 seconden


[Valid News RSS]

RSS Feeds:
[RSS 2.0 News Feed]
[RSS 2.0 Download Feed]
[RSS 2.0 Forum Feed]
[RSS 2.0 Link Feed]
:: fisubsilver shadow phpbb2 style by Daz :: PHP-Nuke theme by BlueLion ::