diff -r ee4defc9321a -r ed4f3ee072be includes/pageprocess.php --- a/includes/pageprocess.php Mon Jan 21 23:02:16 2008 -0500 +++ b/includes/pageprocess.php Tue Jan 22 00:22:14 2008 -0500 @@ -673,7 +673,7 @@ $page_data = $paths->pages[$page_id_key]; $title = ( isset($page_data['name']) ) ? $page_data['name'] : $paths->nslist[$oldtarget[1]] . htmlspecialchars( str_replace('_', ' ', dirtify_page_id( $oldtarget[0] ) ) ); $a = '' . $title . ''; - echo '(Redirected from ' . $a . ')
'; + echo '' . $lang->get('page_msg_redirected_from', array('from' => $a)) . '
'; } } display_page_headers(); @@ -681,7 +681,17 @@ if ( $this->revision_id ) { - echo '
Notice:
The page you are viewing was archived on '.enano_date('F d, Y \a\t h:i a', $this->revision_id).'.
View current version | Restore this version

'; + echo '
+ ' . $lang->get('page_msg_archived_title') . '
+ ' . $lang->get('page_msg_archived_body', array( + 'archive_date' => enano_date('F d, Y', $this->revision_id), + 'archive_time' => enano_date('h:i a', $this->revision_id), + 'current_link' => makeUrlNS($this->namespace, $this->page_id), + 'restore_link' => makeUrlNS($this->namespace, $this->page_id, 'do=rollback&id='.$this->revision_id), + 'restore_onclick' => 'ajaxRollback(\''.$this->revision_id.'\'); return false;', + )) . ' +
+
'; } if ( $redir_enabled ) @@ -948,29 +958,29 @@ // Basic user info - echo 'All about ' . htmlspecialchars($target_username) . ''; + echo '' . $lang->get('userpage_heading_basics', array('username' => htmlspecialchars($target_username))) . ''; if ( $userdata['user_has_avatar'] == '1' ) { echo '' . $lang->get('usercp_avatar_image_alt', array('username' => $userdata['username'])) . ''; } - echo 'Joined: ' . enano_date('F d, Y h:i a', $userdata['reg_time']) . ''; - echo 'Total comments: ' . $userdata['n_comments'] . ''; + echo '' . $lang->get('userpage_lbl_joined') . ' ' . enano_date('F d, Y h:i a', $userdata['reg_time']) . ''; + echo '' . $lang->get('userpage_lbl_num_comments') . ' ' . $userdata['n_comments'] . ''; if ( !empty($userdata['real_name']) ) { - echo 'Real name: ' . $userdata['real_name'] . ''; + echo '' . $lang->get('userpage_lbl_real_name') . ' ' . $userdata['real_name'] . ''; } // Administer user button if ( $session->user_level >= USER_LEVEL_ADMIN ) { - echo 'Administer user'; + echo '' . $lang->get('userpage_btn_administer_user') . ''; } // Comments - echo '' . htmlspecialchars($target_username) . '\'s latest comments'; + echo '' . $lang->get('userpage_heading_comments', array('username' => htmlspecialchars($target_username))) . ''; $q = $db->sql_query('SELECT page_id, namespace, subject, time FROM '.table_prefix.'comments WHERE name=\'' . $db->escape($target_username) . '\' AND user_id=' . $userdata['authoritative_uid'] . ' AND approved=1 ORDER BY time DESC LIMIT 5;'); if ( !$q ) $db->_die(); @@ -1001,7 +1011,7 @@ $tpl = ' class="wikilink-nonexistent">{PAGE}
- Posted {DATE}
+ {lang:userpage_comments_lbl_posted} {DATE}
{SUBJECT} '; @@ -1040,7 +1050,7 @@ } else { - echo 'This user has not posted any comments.'; + echo '' . $lang->get('userpage_msg_no_comments') . ''; } echo ''; @@ -1093,7 +1103,7 @@ // Contact information - echo 'Get in touch'; + echo '' . $lang->get('userpage_heading_contact') . ''; $class = 'row3'; @@ -1101,71 +1111,71 @@ { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; $email_link = $email->encryptEmail($userdata['email']); - echo 'E-mail address: ' . $email_link . ''; + echo '' . $lang->get('userpage_lbl_email') . ' ' . $email_link . ''; } $class = ( $class == 'row1' ) ? 'row3' : 'row1'; if ( $session->user_logged_in ) { - echo 'Send ' . htmlspecialchars($target_username) . ' a Private Message!'; + echo '' . $lang->get('userpage_btn_send_pm', array('username' => htmlspecialchars($target_username), 'pm_link' => makeUrlNS('Special', 'PrivateMessages/Compose/to/' . $this->page_id, false, true))) . ''; } else { - echo 'You could send ' . htmlspecialchars($target_username) . ' a private message if you were logged in.'; + echo '' . $lang->get('userpage_btn_send_pm_guest', array('username' => htmlspecialchars($target_username), 'login_flags' => 'href="' . makeUrlNS('Special', 'Login/' . $paths->nslist[$this->namespace] . $this->page_id) . '" onclick="ajaxStartLogin(); return false;"')) . ''; } if ( !empty($userdata['user_aim']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo 'AIM: ' . $userdata['user_aim'] . ''; + echo '' . $lang->get('userpage_lbl_aim') . ' ' . $userdata['user_aim'] . ''; } if ( !empty($userdata['user_yahoo']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo 'Yahoo! IM: ' . $userdata['user_yahoo'] . ''; + echo '' . $lang->get('userpage_lbl_yim') . ' ' . $userdata['user_yahoo'] . ''; } if ( !empty($userdata['user_msn']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; $email_link = $email->encryptEmail($userdata['user_msn']); - echo 'WLM: ' . $email_link . ''; + echo '' . $lang->get('userpage_lbl_wlm') . ' ' . $email_link . ''; } if ( !empty($userdata['user_xmpp']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; $email_link = $email->encryptEmail($userdata['user_xmpp']); - echo 'XMPP/Jabber: ' . $email_link . ''; + echo '' . $lang->get('userpage_lbl_xmpp') . ' ' . $email_link . ''; } // Real life - echo '' . htmlspecialchars($target_username) . ' in real life'; + echo '' . $lang->get('userpage_heading_real_life', array('username' => htmlspecialchars($target_username))) . ''; if ( !empty($userdata['user_location']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo 'Location: ' . $userdata['user_location'] . ''; + echo '' . $lang->get('userpage_lbl_location') . ' ' . $userdata['user_location'] . ''; } if ( !empty($userdata['user_job']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo 'Job/occupation: ' . $userdata['user_job'] . ''; + echo '' . $lang->get('userpage_lbl_job') . ' ' . $userdata['user_job'] . ''; } if ( !empty($userdata['user_hobbies']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo 'Enjoys: ' . $userdata['user_hobbies'] . ''; + echo '' . $lang->get('userpage_lbl_hobbies') . ' ' . $userdata['user_hobbies'] . ''; } if ( empty($userdata['user_location']) && empty($userdata['user_job']) && empty($userdata['user_hobbies']) ) { $class = ( $class == 'row1' ) ? 'row3' : 'row1'; - echo '' . htmlspecialchars($target_username) . ' hasn\'t posted any real-life contact information.'; + echo '' . $lang->get('userpage_msg_no_contact_info', array('username' => htmlspecialchars($target_username))) . ''; } $code = $plugins->setHook('userpage_sidebar_right'); @@ -1181,7 +1191,10 @@ else: - echo '

Additional information: user "' . htmlspecialchars($target_username) . '" does not exist.

'; + if ( !is_valid_ip($target_username) ) + { + echo '

' . $lang->get('userpage_msg_user_not_exist', array('username' => htmlspecialchars($target_username))) . '

'; + } endif;