[Mise à jour] Upgrade de phpbb 2.0.8a --> 2.0.9

Les différentes versions de phpBB

Modérateur: Guardian

[Mise à jour] Upgrade de phpbb 2.0.8a --> 2.0.9

Messagede rspir le Sam 20 Nov 2004 - 22:06

Voici les modifications pour passer de phpbb 2.0.8.a à la version 2.0.9

Ouvrir admin/admin_board.php
Trouver
Code: Tout sélectionner
     {
        $config_name = $row['config_name'];
        $config_value = $row['config_value'];
       $default_config[$config_name] = $config_value;
       
        $new[$config_name] = ( isset($HTTP_POST_VARS[$config_name]) ) ? $HTTP_POST_VARS[$config_name] : $default_config[$config_name];

Remplacer par
Code: Tout sélectionner
{
        $config_name = $row['config_name'];
        $config_value = $row['config_value'];
       $default_config[$config_name] = str_replace("'", "\'", $config_value);
       
        $new[$config_name] = ( isset($HTTP_POST_VARS[$config_name]) ) ? $HTTP_POST_VARS[$config_name] : $default_config[$config_name];

Ouvrir admin/index.php
Trouver
Code: Tout sélectionner
        WHERE s.session_logged_in = " . TRUE . "
           AND u.user_id = s.session_user_id
           AND u.user_id <> " . ANONYMOUS . "
          AND u.user_session_time >= " . ( time() - 300 ) . "
        ORDER BY u.user_session_time DESC";
     if(!$result = $db->sql_query($sql))
     {

Remplacer par
Code: Tout sélectionner
        WHERE s.session_logged_in = " . TRUE . "
           AND u.user_id = s.session_user_id
           AND u.user_id <> " . ANONYMOUS . "
          AND s.session_time >= " . ( time() - 300 ) . "
        ORDER BY u.user_session_time DESC";
     if(!$result = $db->sql_query($sql))
     {

Ouvrir common.php
Trouver
Code: Tout sélectionner
   die("Hacking attempt");
}

error_reporting  (E_ERROR | E_WARNING | E_PARSE); // This will NOT report uninitialized variables
set_magic_quotes_runtime(0); // Disable magic_quotes_runtime

Remplacer par
Code: Tout sélectionner
     die("Hacking attempt");
  }

//
function unset_vars(&$var)
{
    while (list($var_name, $null) = @each($var))
    {
       unset($GLOBALS[$var_name]);
    }
    return;
}

//
  error_reporting  (E_ERROR | E_WARNING | E_PARSE); // This will NOT report uninitialized variables
  set_magic_quotes_runtime(0); // Disable magic_quotes_runtime

$ini_val = (@phpversion() >= '4.0.0') ? 'ini_get' : 'get_cfg_var';

// Unset globally registered vars - PHP5 ... hhmmm
if (@$ini_val('register_globals') == '1' || strtolower(@$ini_val('register_globals')) == 'on')
{
    $var_prefix = 'HTTP';
    $var_suffix = '_VARS';
   
    $test = array('_GET', '_POST', '_SERVER', '_COOKIE', '_ENV');

    foreach ($test as $var)
    {
       if (is_array(${$var_prefix . $var . $var_suffix}))
       {
          unset_vars(${$var_prefix . $var . $var_suffix});
       }

       if (is_array(${$var}))
       {
          unset_vars(${$var});
       }
    }

    if (is_array(${'_FILES'}))
    {
       unset_vars(${'_FILES'});
    }

    if (is_array(${'HTTP_POST_FILES'}))
    {
       unset_vars(${'HTTP_POST_FILES'});
    }
}

Trouver
Code: Tout sélectionner
$theme = array();
$images = array();
$lang = array();
$gen_simple_header = FALSE;

include($phpbb_root_path . 'config.'.$phpEx);

Remplacer par
Code: Tout sélectionner
  $theme = array();
  $images = array();
  $lang = array();
  $nav_links = array();
  $gen_simple_header = FALSE;

  include($phpbb_root_path . 'config.'.$phpEx);

Trouver
Code: Tout sélectionner
  //
  // Obtain and encode users IP
  //
if( getenv('HTTP_X_FORWARDED_FOR') != '' )
{
    $client_ip = ( !empty($HTTP_SERVER_VARS['REMOTE_ADDR']) ) ? $HTTP_SERVER_VARS['REMOTE_ADDR'] : ( ( empty($HTTP_ENV_VARS['REMOTE_ADDR']) ) ? $HTTP_ENV_VARS['REMOTE_ADDR'] : $REMOTE_ADDR );

    $entries = explode(',', getenv('HTTP_X_FORWARDED_FOR'));
    reset($entries);
    while (list(, $entry) = each($entries))
    {
       $entry = trim($entry);
       if ( preg_match("/^([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)/", $entry, $ip_list) )
       {
          $private_ip = array('/^0\./', '/^127\.0\.0\.1/', '/^192\.168\..*/', '/^172\.((1[6-9])|(2[0-9])|(3[0-1]))\..*/', '/^10\..*/', '/^224\..*/', '/^240\..*/');
          $found_ip = preg_replace($private_ip, $client_ip, $ip_list[1]);

          if ($client_ip != $found_ip)
          {
             $client_ip = $found_ip;
             break;
          }
       }
    }
}
else
{
    $client_ip = ( !empty($HTTP_SERVER_VARS['REMOTE_ADDR']) ) ? $HTTP_SERVER_VARS['REMOTE_ADDR'] : ( ( empty($HTTP_ENV_VARS['REMOTE_ADDR']) ) ? $HTTP_ENV_VARS['REMOTE_ADDR'] : $REMOTE_ADDR );
}
  $user_ip = encode_ip($client_ip);

  //

Remplacer par
Code: Tout sélectionner
  //
  // Obtain and encode users IP
  //
// I'm removing HTTP_X_FORWARDED_FOR ... this may well cause other problems such as
// private range IP's appearing instead of the guilty routable IP, tough, don't
// even bother complaining ... go scream and shout at the idiots out there who feel
// "clever" is doing harm rather than good ... karma is a great thing ... :)
//
$client_ip = ( !empty($HTTP_SERVER_VARS['REMOTE_ADDR']) ) ? $HTTP_SERVER_VARS['REMOTE_ADDR'] : ( ( !empty($HTTP_ENV_VARS['REMOTE_ADDR']) ) ? $HTTP_ENV_VARS['REMOTE_ADDR'] : $REMOTE_ADDR );
  $user_ip = encode_ip($client_ip);

  //

Ouvrir faq.php
Trouver
Code: Tout sélectionner
// End session management
//

//
// Load the appropriate faq file
//

Remplacer par
Code: Tout sélectionner
  // End session management
  //

// Set vars to prevent naughtiness
$faq = array();

  //
  // Load the appropriate faq file
  //

Trouver
Code: Tout sélectionner
  $template->set_filenames(array(
     'body' => 'faq_body.tpl')
  );
make_jumpbox('viewforum.'.$phpEx, $forum_id);

  $template->assign_vars(array(
     'L_FAQ_TITLE' => $l_title,

Remplacer par
Code: Tout sélectionner
  $template->set_filenames(array(
     'body' => 'faq_body.tpl')
  );
make_jumpbox('viewforum.'.$phpEx);

  $template->assign_vars(array(
     'L_FAQ_TITLE' => $l_title,

Ouvrir groupcp.php
Trouver
Code: Tout sélectionner
           $sql = "SELECT g.group_moderator, g.group_type, aa.auth_mod
              FROM " . GROUPS_TABLE . " g, " . AUTH_ACCESS_TABLE . " aa
              WHERE g.group_id = $group_id
                AND aa.group_id = g.group_id(+)";
           break;

        default:

Remplacer par
Code: Tout sélectionner
           $sql = "SELECT g.group_moderator, g.group_type, aa.auth_mod
              FROM " . GROUPS_TABLE . " g, " . AUTH_ACCESS_TABLE . " aa
              WHERE g.group_id = $group_id
                AND aa.group_id (+) = g.group_id";
           break;

        default:

Trouver
Code: Tout sélectionner
   // Select all group that the user is a member of or where the user has
   // a pending membership.
   //
   if ( $userdata['session_logged_in'] )
   {
      $sql = "SELECT g.group_id, g.group_name, g.group_type, ug.user_pending

Remplacer par
Code: Tout sélectionner
     // Select all group that the user is a member of or where the user has
     // a pending membership.
     //
    $in_group = array();
   
     if ( $userdata['session_logged_in'] )
     {
        $sql = "SELECT g.group_id, g.group_name, g.group_type, ug.user_pending

Trouver
Code: Tout sélectionner
           $template->assign_block_vars('switch_groups_remaining', array() );
        }

       $s_hidden_fields = '';

        $template->assign_vars(array(
           'L_GROUP_MEMBERSHIP_DETAILS' => $lang['Group_member_details'],

Remplacer par
Code: Tout sélectionner
           $template->assign_block_vars('switch_groups_remaining', array() );
        }

       $s_hidden_fields = '<input type="hidden" name="sid" value="' . $userdata['session_id'] . '" />';

        $template->assign_vars(array(
           'L_GROUP_MEMBERSHIP_DETAILS' => $lang['Group_member_details'],

Ouvrir includes/bbcode.php
Trouver
Code: Tout sélectionner
     $text = preg_replace("#\[i\](.*?)\[/i\]#si", "[i:$uid]\\1[/i:$uid]", $text);

     // [img]image_url_here[/img] code..
    $text = preg_replace("#\[img\]((ht|f)tp://)([^ \?&=\"\n\r\t<]*?(\.(jpg|jpeg|gif|png)))\[/img\]#sie", "'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);

     // Remove our padding from the string..
     return substr($text, 1);;

Remplacer par
Code: Tout sélectionner
     $text = preg_replace("#\[i\](.*?)\[/i\]#si", "[i:$uid]\\1[/i:$uid]", $text);

     // [img]image_url_here[/img] code..
    $text = preg_replace("#\[img\]((http|ftp|https|ftps)://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png)))\[/img\]#sie", "'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);

     // Remove our padding from the string..
     return substr($text, 1);;

Ouvrir includes/functions_post.php
Trouver
Code: Tout sélectionner
        $gen_simple_header = TRUE;

       $page_title = $lang['Review_topic'] . " - $topic_title";
        include($phpbb_root_path . 'includes/page_header.'.$phpEx);

        $template->set_filenames(array(

Remplacer par
Code: Tout sélectionner
        $gen_simple_header = TRUE;

       $page_title = $lang['Emoticons'] . " - $topic_title";
        include($phpbb_root_path . 'includes/page_header.'.$phpEx);

        $template->set_filenames(array(

Ouvrir includes/page_header.php
Trouver
Code: Tout sélectionner
$logged_hidden_online = 0;
$guests_online = 0;
$online_userlist = '';

if (defined('SHOW_ONLINE'))
{

Remplacer par
Code: Tout sélectionner
  $logged_hidden_online = 0;
  $guests_online = 0;
  $online_userlist = '';
$l_online_users = '';

  if (defined('SHOW_ONLINE'))
  {

Trouver
Code: Tout sélectionner
     $userlist_visible = array();

     $prev_user_id = 0;
    $prev_user_ip = '';

     while( $row = $db->sql_fetchrow($result) )
     {

Remplacer par
Code: Tout sélectionner
     $userlist_visible = array();

     $prev_user_id = 0;
    $prev_user_ip = $prev_session_ip = '';

     while( $row = $db->sql_fetchrow($result) )
     {

Ouvrir includes/sessions.php
Trouver
Code: Tout sélectionner
      $sessionmethod = SESSION_METHOD_GET;
   }

   $last_visit = 0;
   $current_time = time();
   $expiry_time = $current_time - $board_config['session_length'];

Remplacer par
Code: Tout sélectionner
        $sessionmethod = SESSION_METHOD_GET;
     }

    //
    if (!preg_match('/^[A-Za-z0-9]*$/', $session_id))
    {
       $session_id = '';
    }

     $last_visit = 0;
     $current_time = time();
     $expiry_time = $current_time - $board_config['session_length'];

Trouver
Code: Tout sélectionner
   }

   //
   // Does a session exist?
   //
   if ( !empty($session_id) )

Remplacer par
Code: Tout sélectionner
     }

     //
    if (!preg_match('/^[A-Za-z0-9]*$/', $session_id))
    {
       $session_id = '';
    }

    //
     // Does a session exist?
     //
     if ( !empty($session_id) )

Trouver
Code: Tout sélectionner
      $sessionmethod = SESSION_METHOD_GET;
   }

   //
   // Delete existing session
   //

Remplacer par
Code: Tout sélectionner
        $sessionmethod = SESSION_METHOD_GET;
     }

    if (!preg_match('/^[A-Za-z0-9]*$/', $session_id))
    {
       return;
    }
   
     //
     // Delete existing session
     //

Ouvrir includes/usercp_avatar.php
Trouver
Code: Tout sélectionner
        $avatar_filename = 'http://' . $avatar_filename;
     }

    if ( !preg_match('#^((http)|(ftp):\/\/[\w\-]+?\.([\w\-]+\.)+[\w]+(:[0-9]+)*\/.*?\.(gif|jpg|jpeg|png)$)#is', $avatar_filename) )
     {
        $error = true;
        $error_msg = ( !empty($error_msg) ) ? $error_msg . '<br />' . $lang['Wrong_remote_avatar_format'] : $lang['Wrong_remote_avatar_format'];

Remplacer par
Code: Tout sélectionner
        $avatar_filename = 'http://' . $avatar_filename;
     }

    if ( !preg_match("#^((ht|f)tp://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png))$)#is", $avatar_filename) )
     {
        $error = true;
        $error_msg = ( !empty($error_msg) ) ? $error_msg . '<br />' . $lang['Wrong_remote_avatar_format'] : $lang['Wrong_remote_avatar_format'];

Ouvrir includes/usercp_viewprofile.php
Trouver
Code: Tout sélectionner
   message_die(GENERAL_ERROR, 'Could not obtain ranks information', '', __LINE__, __FILE__, $sql);
}

while ( $row = $db->sql_fetchrow($result) )
{
   $ranksrow[] = $row;

Remplacer par
Code: Tout sélectionner
     message_die(GENERAL_ERROR, 'Could not obtain ranks information', '', __LINE__, __FILE__, $sql);
  }

$ranksrow = array();
  while ( $row = $db->sql_fetchrow($result) )
  {
     $ranksrow[] = $row;

Ouvrir index.php
Trouver
Code: Tout sélectionner
   message_die(GENERAL_ERROR, 'Could not query categories list', '', __LINE__, __FILE__, $sql);
}

while( $category_rows[] = $db->sql_fetchrow($result) );
$db->sql_freeresult($result);

Remplacer par
Code: Tout sélectionner
     message_die(GENERAL_ERROR, 'Could not query categories list', '', __LINE__, __FILE__, $sql);
  }

$category_rows = array();
  while( $category_rows[] = $db->sql_fetchrow($result) );
  $db->sql_freeresult($result);

Ouvrir memberlist.php
Trouver
Code: Tout sélectionner
        $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2'];

        $template->assign_block_vars('memberrow', array(
          'ROW_NUMBER' => $i + ( $HTTP_GET_VARS['start'] + 1 ),
           'ROW_COLOR' => '#' . $row_color,
           'ROW_CLASS' => $row_class,
           'USERNAME' => $username,

Remplacer par
Code: Tout sélectionner
        $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2'];

        $template->assign_block_vars('memberrow', array(
          'ROW_NUMBER' => $i + ( $start + 1 ),
           'ROW_COLOR' => '#' . $row_color,
           'ROW_CLASS' => $row_class,
           'USERNAME' => $username,

Ouvrir modcp.php
Trouver
Code: Tout sélectionner

                 'S_FORUM_SELECT' => make_forum_select("new_forum_id", false, $forum_id))
              );

              for($i = 0; $i < $total_posts; $i++)
              {
                 $post_id = $postrow[$i]['post_id'];
                $poster_id = $postrow[$i]['user_id'];
                 $poster = $postrow[$i]['username'];

                 $post_date = create_date($board_config['default_dateformat'], $postrow[$i]['post_time'], $board_config['board_timezone']);

Remplacer par
Code: Tout sélectionner
                 'S_FORUM_SELECT' => make_forum_select("new_forum_id", false, $forum_id))
              );

             //
             // Define censored word matches
             //
             $orig_word = array();
             $replacement_word = array();
             obtain_word_list($orig_word, $replacement_word);

              for($i = 0; $i < $total_posts; $i++)
              {
                 $post_id = $postrow[$i]['post_id'];
                $poster_id = $postrow[$i]['poster_id'];
                 $poster = $postrow[$i]['username'];

                 $post_date = create_date($board_config['default_dateformat'], $postrow[$i]['post_time'], $board_config['board_timezone']);

Trouver
Code: Tout sélectionner
                 {
                    $message = ( $board_config['allow_bbcode'] ) ? bbencode_second_pass($message, $bbcode_uid) : preg_replace('/\:[0-9a-z\:]+\]/si', ']', $message);
                 }

                //
                // Define censored word matches
                //
                $orig_word = array();
                $replacement_word = array();
                obtain_word_list($orig_word, $replacement_word);

                 if ( count($orig_word) )
                 {

Remplacer par
Code: Tout sélectionner
                 {
                    $message = ( $board_config['allow_bbcode'] ) ? bbencode_second_pass($message, $bbcode_uid) : preg_replace('/\:[0-9a-z\:]+\]/si', ']', $message);
                 }

                 if ( count($orig_word) )
                 {

Ouvrir posting.php
Trouver
Code: Tout sélectionner
  //
  // Check and set various parameters
  //
$params = array('submit' => 'post', 'confirm' => 'confirm', 'preview' => 'preview', 'delete' => 'delete', 'poll_delete' => 'poll_delete', 'poll_add' => 'add_poll_option', 'poll_edit' => 'edit_poll_option', 'mode' => 'mode');
  while( list($var, $param) = @each($params) )
  {
     if ( !empty($HTTP_POST_VARS[$param]) || !empty($HTTP_GET_VARS[$param]) )

Remplacer par
Code: Tout sélectionner
  //
  // Check and set various parameters
  //
$params = array('submit' => 'post', 'preview' => 'preview', 'delete' => 'delete', 'poll_delete' => 'poll_delete', 'poll_add' => 'add_poll_option', 'poll_edit' => 'edit_poll_option', 'mode' => 'mode');
  while( list($var, $param) = @each($params) )
  {
     if ( !empty($HTTP_POST_VARS[$param]) || !empty($HTTP_GET_VARS[$param]) )

Trouver
Code: Tout sélectionner
      $$var = '';
   }
}

$params = array('forum_id' => POST_FORUM_URL, 'topic_id' => POST_TOPIC_URL, 'post_id' => POST_POST_URL);
while( list($var, $param) = @each($params) )

Remplacer par
Code: Tout sélectionner
        $$var = '';
     }
  }

$confirm = isset($HTTP_POST_VARS['confirm']) ? true : false;

  $params = array('forum_id' => POST_FORUM_URL, 'topic_id' => POST_TOPIC_URL, 'post_id' => POST_POST_URL);
  while( list($var, $param) = @each($params) )

Ouvrir privmsg.php
Trouver
Code: Tout sélectionner
           break;
        case 'savebox':
           $l_box_name = $lang['Savebox'];
          $pm_sql_user .= "AND ( ( pm.privmsgs_to_userid = " . $userdata['user_id'] . "
                 AND pm.privmsgs_type = " . PRIVMSGS_SAVED_IN_MAIL . " )
              OR ( pm.privmsgs_from_userid = " . $userdata['user_id'] . "
                 AND pm.privmsgs_type = " . PRIVMSGS_SAVED_OUT_MAIL . " )

Remplacer par
Code: Tout sélectionner
           break;
        case 'savebox':
           $l_box_name = $lang['Savebox'];
          $pm_sql_user = "AND ( ( pm.privmsgs_to_userid = " . $userdata['user_id'] . "
                 AND pm.privmsgs_type = " . PRIVMSGS_SAVED_IN_MAIL . " )
              OR ( pm.privmsgs_from_userid = " . $userdata['user_id'] . "
                 AND pm.privmsgs_type = " . PRIVMSGS_SAVED_OUT_MAIL . " )

Trouver
Code: Tout sélectionner
     $profile_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_profile'] . '" alt="' . $lang['Read_profile'] . '" title="' . $lang['Read_profile'] . '" border="0" /></a>';
     $profile = '<a href="' . $temp_url . '">' . $lang['Read_profile'] . '</a>';

    $temp_url = append_sid("privmsg.$phpEx?mode=post&amp;" . POST_USERS_URL . "=$poster_id");
     $pm_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_pm'] . '" alt="' . $lang['Send_private_message'] . '" title="' . $lang['Send_private_message'] . '" border="0" /></a>';
     $pm = '<a href="' . $temp_url . '">' . $lang['Send_private_message'] . '</a>';

Remplacer par
Code: Tout sélectionner
     $profile_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_profile'] . '" alt="' . $lang['Read_profile'] . '" title="' . $lang['Read_profile'] . '" border="0" /></a>';
     $profile = '<a href="' . $temp_url . '">' . $lang['Read_profile'] . '</a>';

    $temp_url = append_sid("privmsg.$phpEx?mode=post&amp;" . POST_USERS_URL . "=$user_id_from");
     $pm_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_pm'] . '" alt="' . $lang['Send_private_message'] . '" title="' . $lang['Send_private_message'] . '" border="0" /></a>';
     $pm = '<a href="' . $temp_url . '">' . $lang['Send_private_message'] . '</a>';

Trouver
Code: Tout sélectionner
              $saved_sql .= " SET privmsgs_type = " . PRIVMSGS_SAVED_OUT_MAIL . "
                 WHERE privmsgs_from_userid = " . $userdata['user_id'] . "
                    AND ( privmsgs_type = " . PRIVMSGS_NEW_MAIL . "
                      OR privmsgs_type = " . PRIVMSGS_UNERAD_MAIL . " ) ";
              break;

           case 'sentbox':

Remplacer par
Code: Tout sélectionner
              $saved_sql .= " SET privmsgs_type = " . PRIVMSGS_SAVED_OUT_MAIL . "
                 WHERE privmsgs_from_userid = " . $userdata['user_id'] . "
                    AND ( privmsgs_type = " . PRIVMSGS_NEW_MAIL . "
                      OR privmsgs_type = " . PRIVMSGS_UNREAD_MAIL . " ) ";
              break;

           case 'sentbox':

Trouver
Code: Tout sélectionner
  //
  // New message
  //
$post_new_mesg_url = '<a href="' . append_sid("privmsg.$phpEx?mode=post") . '"><img src="' . $images['post_new'] . '" alt="' . $lang['Post_new_message'] . '" border="0" /></a>';

  //
  // General SQL to obtain messages

Remplacer par
Code: Tout sélectionner
  //
  // New message
  //
$post_new_mesg_url = '<a href="' . append_sid("privmsg.$phpEx?mode=post") . '"><img src="' . $images['post_new'] . '" alt="' . $lang['Send_a_new_message'] . '" border="0" /></a>';

  //
  // General SQL to obtain messages

Trouver
Code: Tout sélectionner
  }
  else
  {
    $limit_msg_time = '';
    $post_days = 0;
  }

  $sql .= $limit_msg_time . " ORDER BY pm.privmsgs_date DESC LIMIT $start, " . $board_config['topics_per_page'];

Remplacer par
Code: Tout sélectionner
  }
  else
  {
    $limit_msg_time = $limit_msg_time_total = '';
    $msg_days = 0;
  }

  $sql .= $limit_msg_time . " ORDER BY pm.privmsgs_date DESC LIMIT $start, " . $board_config['topics_per_page'];

Trouver
Code: Tout sélectionner
     'S_POST_NEW_MSG' => $post_new_mesg_url,
     'S_SELECT_MSG_DAYS' => $select_msg_days,

    'U_POST_NEW_TOPIC' => $post_new_topic_url)
  );

  //

Remplacer par
Code: Tout sélectionner
     'S_POST_NEW_MSG' => $post_new_mesg_url,
     'S_SELECT_MSG_DAYS' => $select_msg_days,

    'U_POST_NEW_TOPIC' => append_sid("privmsg.$phpEx?mode=post"))
  );

  //

Ouvrir profile.php
Trouver
Code: Tout sélectionner
if ( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
{
   $mode = ( isset($HTTP_GET_VARS['mode']) ) ? $HTTP_GET_VARS['mode'] : $HTTP_POST_VARS['mode'];

   if ( $mode == 'viewprofile' )
   {

Remplacer par
Code: Tout sélectionner
  if ( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
  {
     $mode = ( isset($HTTP_GET_VARS['mode']) ) ? $HTTP_GET_VARS['mode'] : $HTTP_POST_VARS['mode'];
    $mode = htmlspecialchars($mode);

     if ( $mode == 'viewprofile' )
     {

Ouvrir search.php
Trouver
Code: Tout sélectionner
if ( !empty($HTTP_POST_VARS['search_time']) || !empty($HTTP_GET_VARS['search_time']))
{
   $search_time = time() - ( ( ( !empty($HTTP_POST_VARS['search_time']) ) ? intval($HTTP_POST_VARS['search_time']) : intval($HTTP_GET_VARS['search_time']) ) * 86400 );
}
else
{
   $search_time = 0;
}

$start = ( isset($HTTP_GET_VARS['start']) ) ? intval($HTTP_GET_VARS['start']) : 0;

Remplacer par
Code: Tout sélectionner
  if ( !empty($HTTP_POST_VARS['search_time']) || !empty($HTTP_GET_VARS['search_time']))
  {
     $search_time = time() - ( ( ( !empty($HTTP_POST_VARS['search_time']) ) ? intval($HTTP_POST_VARS['search_time']) : intval($HTTP_GET_VARS['search_time']) ) * 86400 );
    $topic_days = (!empty($HTTP_POST_VARS['search_time'])) ? intval($HTTP_POST_VARS['search_time']) : intval($HTTP_GET_VARS['search_time']);
  }
  else
  {
     $search_time = 0;
    $topic_days = 0;
  }

  $start = ( isset($HTTP_GET_VARS['start']) ) ? intval($HTTP_GET_VARS['start']) : 0;

Ouvrir viewonline.php
Trouver
Code: Tout sélectionner
  make_jumpbox('viewforum.'.$phpEx);

  $template->assign_vars(array(
    'L_WHOSONLINE' => $lang['Who_is_online'],
     'L_ONLINE_EXPLAIN' => $lang['Online_explain'],
     'L_USERNAME' => $lang['Username'],
     'L_FORUM_LOCATION' => $lang['Forum_Location'],

Remplacer par
Code: Tout sélectionner
  make_jumpbox('viewforum.'.$phpEx);

  $template->assign_vars(array(
    'L_WHOSONLINE' => $lang['Who_is_Online'],
     'L_ONLINE_EXPLAIN' => $lang['Online_explain'],
     'L_USERNAME' => $lang['Username'],
     'L_FORUM_LOCATION' => $lang['Forum_Location'],

Ouvrir viewtopic.php
Trouver
Code: Tout sélectionner
      if ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid']) || isset($HTTP_GET_VARS['sid']) )
      {
         $session_id = isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid']) ? $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid'] : $HTTP_GET_VARS['sid'];

         if ( $session_id )
         {

Remplacer par
Code: Tout sélectionner
        if ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid']) || isset($HTTP_GET_VARS['sid']) )
        {
           $session_id = isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid']) ? $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_sid'] : $HTTP_GET_VARS['sid'];

          if (!preg_match('/^[A-Za-z0-9]*$/', $session_id))
          {
             $session_id = '';
         }

           if ( $session_id )
           {
RSPIR

Tant qu'à faire le mal, faites le bien ! Parce que bien faire le mal, c'est tout comme mal faire le bien. Mais bien faire le bien, c'est mieux que de mal faire le mal, non ?
Avatar de l’utilisateur
rspir
Modérateur
 
Messages: 321
Inscription: Dim 8 Aoû 2004 - 11:45
Localisation: Bordeaux (33)

Messagede belver le Sam 20 Nov 2004 - 22:38

ouah!
t'es déchainé ce soir rspir smiley_500
J'ai encore perdu une occasion de me taire
Assistance Informatique en live
Image Image
Avatar de l’utilisateur
belver
Administrateur
 
Messages: 5132
Inscription: Mar 3 Aoû 2004 - 10:40
Localisation: Nantes

Messagede rspir le Dim 21 Nov 2004 - 10:56

Ouaip ...
J'ai profité de la sortie de nouvelle release pour mettre à jour notre forum avec toutes les maj manuelle de la 2.08 à la 2.11
RSPIR

Tant qu'à faire le mal, faites le bien ! Parce que bien faire le mal, c'est tout comme mal faire le bien. Mais bien faire le bien, c'est mieux que de mal faire le mal, non ?
Avatar de l’utilisateur
rspir
Modérateur
 
Messages: 321
Inscription: Dim 8 Aoû 2004 - 11:45
Localisation: Bordeaux (33)


Retourner vers Versions phpBB

Qui est en ligne

Utilisateurs parcourant ce forum: Aucun utilisateur enregistré et 1 invité

cron