############################################################################################################################ 
## MOD Titel: Edit/Delete_only_last_post(rus)
## MOD Version: 1.01. - 7.03.2007 (rus)
## MOD Author: A. Oymann / www.retriever-hilfe.de / webmaster@retriever-hilfe.de 
## MOD : Andre:-)
## MOD :           . 
## MOD :  
## MOD   phpBB: 2.0.21
## MOD  : 4 
##   (3): 
## posting.php 
## viewtopic.php 
## language/lang_russian/lang_main.php 
############################################################################################################################    
## This MOD is released under the GPL License. 
## Intellectual Property is retained by the MOD Author(s) listed above 
## http://www.gnu.org 
############################################################################################################################ 
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD !!! 
## 
##      ,       !!! 
############################################################################################################################ 

 : 

############################################################################################################################ 

# 
#-----[ OPEN ]------------------------------------------ 
# 
posting.php 

# 
#-----[ FIND ]------------------------------------------ 
# 
      if ( $post_info['poster_id'] != $userdata['user_id'] && !$is_auth['auth_mod'] ) 
      { 
         $message = ( $delete || $mode == 'delete' ) ? $lang['Delete_own_posts'] : $lang['Edit_own_posts']; 
         $message .= '<br /><br />' . sprintf($lang['Click_return_topic'], '<a href="' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">', '</a>'); 

         message_die(GENERAL_MESSAGE, $message); 
      } 

# 
#-----[ AFTER, ADD ]------------------------------------------ 
# 
      else if ( !$post_data['last_post'] && !$is_auth['auth_mod'] ) 
      { 
         $message = ( $delete || $mode == 'delete' ) ? $lang['Delete_last_posts'] : $lang['Edit_last_posts']; 
         $message .= '<br /><br />' . sprintf($lang['Click_return_topic'], '<a href="' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">', '</a>'); 

         message_die(GENERAL_MESSAGE, $message); 
      } 

# 
#-----[ OPEN ]------------------------------------------ 
# 
viewtopic.php 

# 
#-----[ FIND ]------------------------------------------ 
#  
   if ( ( $userdata['user_id'] == $poster_id && $is_auth['auth_edit'] ) || $is_auth['auth_mod'] ) 
   { 
      $temp_url = append_sid("posting.$phpEx?mode=editpost&amp;" . POST_POST_URL . "=" . $postrow[$i]['post_id']); 
      $edit_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_edit'] . '" alt="' . $lang['Edit_delete_post'] . '" title="' . $lang['Edit_delete_post'] . '" border="0" /></a>'; 
      $edit = '<a href="' . $temp_url . '">' . $lang['Edit_delete_post'] . '</a>'; 
   } 

# 
#-----[ REPLACE WITH ]------------------------------------------ 
#  
   if ( ( $userdata['user_id'] == $poster_id && $is_auth['auth_edit'] && $forum_topic_data['topic_last_post_id'] == $postrow[$i]['post_id'] ) || $is_auth['auth_mod'] ) 
   { 
      $temp_url = append_sid("posting.$phpEx?mode=editpost&amp;" . POST_POST_URL . "=" . $postrow[$i]['post_id']); 
      $edit_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_edit'] . '" alt="' . $lang['Edit_delete_post'] . '" title="' . $lang['Edit_delete_post'] . '" border="0" /></a>'; 
      $edit = '<a href="' . $temp_url . '">' . $lang['Edit_delete_post'] . '</a>'; 
   } 


# 
#-----[ OPEN ]------------------------------------------ 
# 
language/lang_russian/lang_main.php 


# 
#-----[ FIND ]------------------------------------------ 
#    
$lang['Delete_own_posts'] = ',       ';

# 
#-----[ AFTER, ADD ]------------------------------------------ 
# 
$lang['Edit_last_posts'] = ',         .'; 
$lang['Delete_last_posts'] = ',         .'; 
  
# 
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------ 
# 
# EoM 